Files
queueful/docker-compose.yml

61 lines
1.2 KiB
YAML

services:
backend:
build:
context: backend
dockerfile: ./Dockerfile.prod
restart: unless-stopped
ports:
- "8000"
env_file:
- path: ./env/backend/prod.env
required: true
networks:
- db
- default
depends_on:
redis:
condition: service_healthy
nginx:
build:
dockerfile: ./nginx/Dockerfile
restart: unless-stopped
volumes:
- ./static:/static
depends_on:
- backend
ports:
- "8880:80"
networks:
- default
# postgres:
# image: postgres:16.2-alpine
# restart: unless-stopped
# ports:
# - "5432:5432"
# volumes:
# - ./postgres_data:/var/lib/postgresql/data/
# env_file:
# - path: ./env/postgres.env
# required: true
# healthcheck:
# test:
# ["CMD-SHELL", "pg_isready -d $${POSTGRES_DB} --user $${POSTGRES_USER}"]
# interval: 2s
# timeout: 2s
# retries: 5
redis:
image: redis:7.2.4-alpine
restart: unless-stopped
ports:
- 6379
healthcheck:
test: ["CMD", "redis-cli", "--raw", "incr", "ping"]
interval: 2s
timeout: 2s
retries: 5
networks:
db:
name: docker-net
external: true