Sogo: change config 2

This commit is contained in:
Ruben Hensen
2026-01-26 01:16:45 +01:00
parent 285a0b0b9a
commit 92754c17b0
+6 -3
View File
@@ -19,13 +19,16 @@ spec:
spec:
initContainers:
- name: config-init
image: bhgedigital/envsubst:latest
image: alpine:latest
command:
- sh
- -c
- |
envsubst < /config-template/sogo.yaml > /config/sogo.yaml
echo "Configuration file prepared"
apk add --no-cache python3
ENCODED_PASSWORD=$(python3 -c "import urllib.parse; print(urllib.parse.quote('${POSTGRES_PASSWORD}', safe=''))")
export POSTGRES_PASSWORD="${ENCODED_PASSWORD}"
cat /config-template/sogo.yaml | sed "s|\${POSTGRES_PASSWORD}|${POSTGRES_PASSWORD}|g" > /config/sogo.yaml
echo "Configuration file prepared with URL-encoded password"
env:
- name: POSTGRES_PASSWORD
valueFrom: