Last active
April 13, 2024 09:31
-
-
Save idfumg/c0c2f2ef4ec26be6363dc63b469a733b to your computer and use it in GitHub Desktop.
Postgresql docker compose file for testing purposes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
postgres: | |
image: 'postgres:14.5' | |
container_name: "postgres_isolation" | |
restart: always | |
environment: | |
- POSTGRES_DB=isolation_levels | |
- POSTGRES_USER=postgres | |
- POSTGRES_PASSWORD=postgres | |
logging: | |
options: | |
max-size: 10m | |
max-file: "3" | |
ports: | |
- '5432:5432' | |
networks: | |
- fullstack | |
volumes: | |
- ./db-data:/var/lib/postgresql/data | |
networks: | |
fullstack: | |
driver: bridge |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Start:
docker-compose -f pg-docker-compose.yml up
Stop:
docker-compose -f pg-docker-compose.yml down