Skip to content

Instantly share code, notes, and snippets.

@enesusta
Last active March 17, 2020 13:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save enesusta/c305937e9bff70f53657310e16accd99 to your computer and use it in GitHub Desktop.
Save enesusta/c305937e9bff70f53657310e16accd99 to your computer and use it in GitHub Desktop.
version: '3.1'
services:
db:
container_name: postgres_container
image: postgres
restart: always
ports:
- 5432:5432
environment:
POSTGRES_USER: ${your_user}
POSTGRES_PASSWORD: ${your_password}
TZ: 'Europe/Istanbul'
PGTZ: 'Europe/Istanbul'
volumes:
- ./init.sql:/docker-entrypoint-initdb.d/init.sql
- pgdata:/var/lib/postgresql/data
- pgconf:/etc/postgresql
- pglog:/var/log/postgresql
pgadmin:
container_name: pgadmin_container
image: dpage/pgadmin4
ports:
- 81:80
environment:
PGADMIN_DEFAULT_EMAIL: ${email}
PGADMIN_DEFAULT_PASSWORD: ${pass}
volumes:
pgdata:
driver: local
pgconf:
driver: local
pglog:
driver: local
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment