Skip to content

Instantly share code, notes, and snippets.

@mvodep
Created April 22, 2021 09:52
Show Gist options
  • Save mvodep/ac031410881a051997eacd420e7ea4c1 to your computer and use it in GitHub Desktop.
Save mvodep/ac031410881a051997eacd420e7ea4c1 to your computer and use it in GitHub Desktop.
version: "3.1"
services:
db:
image: postgres
command: ["postgres", "-c", "logging_collector=on", "-c", "log_directory=/var/log/postgresql", "-c", "log_filename=postgresql.log", "-c", "log_statement=all"]
restart: always
environment:
POSTGRES_PASSWORD: postgres
volumes:
- postgres-volume:/var/lib/postgresql/data
- ./init.sql:/docker-entrypoint-initdb.d/init.sql
ports:
- 5432:5432
volumes:
postgres-volume:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment