Skip to content

Instantly share code, notes, and snippets.

@bndabbs
Created May 12, 2022 15:16
Show Gist options
  • Save bndabbs/0e343dfc1eb1b5196d7910cb4b943de5 to your computer and use it in GitHub Desktop.
Save bndabbs/0e343dfc1eb1b5196d7910cb4b943de5 to your computer and use it in GitHub Desktop.
Self-host jqplay with Docker Compose
# Clone https://github.com/owenthereal/jqplay and then save this compose file into the cloned directory
version: "3.0"
services:
jqplay:
build: .
restart: always
environment:
DATABASE_URL: "postgresql://postgres@db:5432"
depends_on:
db:
condition: service_healthy
networks:
- app
- db
ports:
- 8080:80
db:
image: postgres
restart: always
environment:
POSTGRES_HOST_AUTH_METHOD: trust
healthcheck:
test: ["CMD", "pg_isready", "-h", "localhost", "-U", "postgres"]
interval: 10s
timeout: 5s
retries: 5
networks:
- db
volumes:
- postgres_data:/var/lib/postgresql/data:rw
networks:
db:
internal: true
app:
volumes:
postgres_data:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment