Skip to content

Commit

Permalink
Change server key file permission according to PSQL requirement
Browse files Browse the repository at this point in the history
  • Loading branch information
SviatoslavBoichuk committed Jul 31, 2024
1 parent 91f3996 commit 8931f2f
Showing 1 changed file with 7 additions and 12 deletions.
19 changes: 7 additions & 12 deletions utils/docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,18 +32,13 @@ services:
image: "postgres:latest"
ports:
- "5432:5432"
command:
- "postgres"
- "-c"
- "max_connections=400"
- "-c"
- "shared_buffers=20MB"
- "-c"
- "ssl=on"
- "-c"
- "ssl_cert_file=/var/lib/postgresql/certs/server.crt"
- "-c"
- "ssl_key_file=/var/lib/postgresql/certs/server.key"
user: postgres
command: >
bash -c "
chown 999:999 /var/lib/postgresql/certs/server.key &&
chmod 600 /var/lib/postgresql/certs/server.key &&
postgres -c max_connections=400 -c shared_buffers=20MB -c ssl=on -c ssl_cert_file=/var/lib/postgresql/certs/server.crt -c ssl_key_file=/var/lib/postgresql/certs/server.key
"
env_file:
- postgresql.env
restart: always
Expand Down

0 comments on commit 8931f2f

Please sign in to comment.