mirror of
https://github.com/bitwarden/self-host.git
synced 2026-06-27 22:05:45 +00:00
Add SSL certificates to the trusted CA store (#510)
This commit is contained in:
@@ -62,6 +62,7 @@ ENV globalSettings__logRollBySizeLimit="1073741824"
|
|||||||
|
|
||||||
# Add packages
|
# Add packages
|
||||||
RUN apk add --no-cache \
|
RUN apk add --no-cache \
|
||||||
|
ca-certificates \
|
||||||
curl \
|
curl \
|
||||||
jq \
|
jq \
|
||||||
nginx \
|
nginx \
|
||||||
|
|||||||
@@ -83,6 +83,15 @@ if [ "$BW_ENABLE_SSL" = "true" ] && [ ! -f /etc/bitwarden/${BW_SSL_KEY:-ssl.key}
|
|||||||
rm "$TMP_OPENSSL_CONF"
|
rm "$TMP_OPENSSL_CONF"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Trust the configured SSL certificates
|
||||||
|
if [ "$BW_ENABLE_SSL" = "true" ]; then
|
||||||
|
cp /etc/bitwarden/${BW_SSL_CERT:-ssl.crt} /usr/local/share/ca-certificates/bitwarden.crt
|
||||||
|
if [ -f /etc/bitwarden/${BW_SSL_CA_CERT:-ca.crt} ]; then
|
||||||
|
cp /etc/bitwarden/${BW_SSL_CA_CERT:-ca.crt} /usr/local/share/ca-certificates/bitwarden-ca.crt
|
||||||
|
fi
|
||||||
|
update-ca-certificates >/dev/null
|
||||||
|
fi
|
||||||
|
|
||||||
# Launch a loop to rotate nginx logs on a daily basis
|
# Launch a loop to rotate nginx logs on a daily basis
|
||||||
/bin/sh -c "/logrotate.sh loop >/dev/null 2>&1 &"
|
/bin/sh -c "/logrotate.sh loop >/dev/null 2>&1 &"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user