9 lines
393 B
Bash
9 lines
393 B
Bash
#!/bin/sh
|
|
set -eu
|
|
mkdir -p /tmp/pg-tls
|
|
cp /run/tls/cert.crt /tmp/pg-tls/cert.crt
|
|
cp /run/tls/key.key /tmp/pg-tls/key.key
|
|
chown -R postgres:postgres /tmp/pg-tls
|
|
chmod 600 /tmp/pg-tls/key.key
|
|
exec /usr/local/bin/docker-entrypoint.sh postgres -c ssl=on -c ssl_cert_file=/tmp/pg-tls/cert.crt -c ssl_key_file=/tmp/pg-tls/key.key -c hba_file=/config/pg_hba.conf -c password_encryption=scram-sha-256
|