Files
queueful/dev.yml
2024-05-10 15:11:25 +03:00

66 lines
1.4 KiB
YAML

services:
backend:
build:
context: backend
restart: unless-stopped
ports:
- "8000"
env_file:
- path: ./env/backend/dev.env
required: true
volumes:
- ./backend/app:/code/app:z
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_healthy
frontend:
build:
context: frontend
restart: unless-stopped
ports:
- "3000"
env_file:
- path: ./env/frontend/dev.env
required: true
volumes:
- ./frontend/app:/app:z
nginx:
image: nginx:1.25.4-alpine
restart: unless-stopped
volumes:
- ./nginx/dev.conf:/etc/nginx/conf.d/default.conf:ro
- ./static:/static
depends_on:
- backend
- frontend
ports:
- "80:80"
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