Skip to content

Instantly share code, notes, and snippets.

@gaurangrshah
Created January 28, 2024 20:35
Show Gist options
  • Save gaurangrshah/84994d3bbb39fa81a0cbb2660d5e0e83 to your computer and use it in GitHub Desktop.
Save gaurangrshah/84994d3bbb39fa81a0cbb2660d5e0e83 to your computer and use it in GitHub Desktop.
postgres + adminer setup to complement a nodejs project
version: '3'
services:
db:
image: postgres
restart: always
volumes:
- ./data/db:/var/lib/postgresql/data
ports:
- 5432:5432
environment:
- POSTGRES_DB=testDB
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
adminer:
image: adminer
restart: always
ports:
- 8080:8080
# this starts a postgres service @ localhost:5432 and takes the data from the ./data/db folder
# adminer is a web interface for postgres @ localhost:8080
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment