build: add api, worker, and migrate services to docker-compose

This commit is contained in:
agatha 2026-03-15 15:30:59 -04:00
parent a0fdd0f51c
commit 6da6dcd33a

View File

@ -1,4 +1,37 @@
services:
api:
build: .
ports:
- "8000:8000"
env_file: .env
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_healthy
volumes:
- ./plugins-contrib:/app/plugins-contrib:ro
worker:
build: .
command: ["arq", "proxy_pool.worker.settings.WorkerSettings"]
env_file: .env
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_healthy
migrate:
build: .
command: ["alembic", "upgrade", "head"]
env_file: .env
depends_on:
postgres:
condition: service_healthy
profiles:
- migrate
postgres:
image: postgres:16-alpine
environment: