nl2sql-copilot / docker-compose.yml
Melika Kheirieh
feat(metrics): enable repair tracking and Prometheus lifecycle for observability
666306b
raw
history blame
986 Bytes
services:
api:
environment:
POSTGRES_DSN: dbname=demo user=postgres password=postgres host=postgres port=5432
OPENAI_MODEL: gpt-4o-mini
OPENAI_API_KEY: ${OPENAI_API_KEY}
ports:
- "8000:8000"
command: ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8000", "--proxy-headers"]
prometheus:
image: prom/prometheus:latest
container_name: prometheus
restart: unless-stopped
ports:
- "9090:9090"
volumes:
# πŸ“˜ Prometheus config
- ./provisioning/prometheus/prometheus.yml:/etc/prometheus/prometheus.yml:ro
# πŸ“˜ Rules (recording + alert rules)
- ./provisioning/prometheus/rules.yml:/etc/prometheus/rules.yml:ro
# πŸ“˜ Persistent TSDB storage
- prometheus_data:/prometheus
command:
- "--config.file=/etc/prometheus/prometheus.yml"
- "--storage.tsdb.path=/prometheus"
- "--web.enable-lifecycle"
- "--web.enable-admin-api"
volumes:
prometheus_data: