Skip to content

Instantly share code, notes, and snippets.

@Alireza2n
Last active May 22, 2019 15:49
Show Gist options
  • Save Alireza2n/47bb69a0bada653dc748e83908da733d to your computer and use it in GitHub Desktop.
Save Alireza2n/47bb69a0bada653dc748e83908da733d to your computer and use it in GitHub Desktop.
A docker compose file to quickly run a Postgresql instance on localhost, using tmpfs (ram) as main data storage. Optionally loads *.sql files in docker-entrypoint-initdb.d into newly created database. This is meant for fast development and NOT production.
version: "3"
services:
db:
image: postgres:10
restart: "no"
ports:
- 5432:5432
volumes:
- ./docker/db/docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d:ro
environment:
POSTGRES_USER: some-user
POSTGRES_PASSWORD: some-passowrd
POSTGRES_DB: some-db-name
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment