diff --git a/src/Api/entrypoint.sh b/src/Api/entrypoint.sh index 3533cda98..1c3d96ef9 100644 --- a/src/Api/entrypoint.sh +++ b/src/Api/entrypoint.sh @@ -24,9 +24,13 @@ chown -R $USERNAME:$USERNAME /app chown -R $USERNAME:$USERNAME /jobs mkdir -p /etc/bitwarden/core mkdir -p /etc/bitwarden/logs +mkdir -p /etc/bitwarden/ca-certificates chown -R $USERNAME:$USERNAME /etc/bitwarden env >> /etc/environment cron +cp /etc/bitwarden/ca-certificates/*.crt /usr/local/share/ca-certificates/ \ + && update-ca-certificates + gosu bitwarden:bitwarden dotnet /app/Api.dll diff --git a/src/Identity/entrypoint.sh b/src/Identity/entrypoint.sh index ab37a9c7f..99d238c39 100644 --- a/src/Identity/entrypoint.sh +++ b/src/Identity/entrypoint.sh @@ -21,9 +21,13 @@ fi mkdir -p /etc/bitwarden/identity mkdir -p /etc/bitwarden/core mkdir -p /etc/bitwarden/logs +mkdir -p /etc/bitwarden/ca-certificates chown -R $USERNAME:$USERNAME /etc/bitwarden cp /etc/bitwarden/identity/identity.pfx /app/identity.pfx chown -R $USERNAME:$USERNAME /app +cp /etc/bitwarden/ca-certificates/*.crt /usr/local/share/ca-certificates/ \ + && update-ca-certificates + gosu $USERNAME:$USERNAME dotnet /app/Identity.dll diff --git a/util/Setup/DockerComposeBuilder.cs b/util/Setup/DockerComposeBuilder.cs index f90fb88b3..17e07de2a 100644 --- a/util/Setup/DockerComposeBuilder.cs +++ b/util/Setup/DockerComposeBuilder.cs @@ -148,6 +148,7 @@ services: restart: always volumes: - ../core:/etc/bitwarden/core + - ../ca-certificates:/etc/bitwarden/ca-certificates - ../logs/api:/etc/bitwarden/logs env_file: - global.env @@ -161,6 +162,7 @@ services: volumes: - ../identity:/etc/bitwarden/identity - ../core:/etc/bitwarden/core + - ../ca-certificates:/etc/bitwarden/ca-certificates - ../logs/identity:/etc/bitwarden/logs env_file: - global.env