Prepare private pgpass in region init container
Foundation / checks (checks) (push) Successful in 4s
Foundation / checks (client) (push) Successful in 5s
Foundation / checks (ecs) (push) Successful in 4s
Foundation / checks (network) (push) Successful in 4s
Foundation / checks (postgres) (push) Successful in 4s
Foundation / checks (tsan) (push) Successful in 4s
Foundation / postgres-tools (push) Canceled after 0s
Foundation / server-image (push) Canceled after 0s
Foundation / image (push) Canceled after 0s
Foundation / checks (deploy) (push) Canceled after 1m43s

This commit is contained in:
aevolution-gitops-bot
2026-10-05 09:13:17 -04:00
parent 4cdb41133c
commit cd91dee95a
+16 -4
View File
@@ -42,17 +42,29 @@ spec:
fsGroup: 10001
fsGroupChangePolicy: Always
seccompProfile: {type: RuntimeDefault}
initContainers:
- name: prepare-pgpass
image: aevolution-server
command: ["/bin/bash", "-c"]
args: ["set -eu; umask 077; cp /run/postgres/pgpass /tmp/pgpass; chmod 0600 /tmp/pgpass"]
securityContext:
runAsUser: 0
runAsGroup: 0
runAsNonRoot: false
allowPrivilegeEscalation: false
readOnlyRootFilesystem: true
capabilities: {drop: [ALL]}
volumeMounts:
- {name: connection, mountPath: /run/postgres, readOnly: true}
- {name: scratch, mountPath: /tmp}
containers:
- name: evo-server
image: aevolution-server
# libpq ignores group-readable password files: copy to private memory, then
# exec so evo-server is PID 1 and receives SIGTERM directly.
# The init container copies pgpass to private memory, then exec so evo-server is PID 1 and receives SIGTERM directly.
command: ["/bin/bash", "-c"]
args:
- |
set -eu
umask 077
cp /run/postgres/pgpass /tmp/pgpass
# Builds that wrote this region's history stay recoverable (ADR-0068).
retained=()
for build in $REGION_RETAINED; do retained+=(--retained "$build"); done