services: db: image: postgres:16-alpine restart: unless-stopped environment: POSTGRES_DB: scope_builder POSTGRES_USER: scope_user POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-scope_pass_2024} ports: - "5433:5432" volumes: - pgdata:/var/lib/postgresql/data healthcheck: test: ["CMD-SHELL", "pg_isready -U scope_user -d scope_builder"] interval: 5s timeout: 3s retries: 5 backend: build: ./backend restart: unless-stopped depends_on: db: condition: service_healthy environment: DATABASE_URL: postgresql+asyncpg://scope_user:${POSTGRES_PASSWORD:-scope_pass_2024}@db:5432/scope_builder DATABASE_URL_SYNC: postgresql://scope_user:${POSTGRES_PASSWORD:-scope_pass_2024}@db:5432/scope_builder ANTHROPIC_API_KEY: ${ANTHROPIC_API_KEY} ports: - "8001:8000" volumes: - ./backend:/app - ./data:/app/data frontend: build: ./frontend restart: unless-stopped depends_on: - backend ports: - "3010:3000" volumes: - ./frontend/src:/app/src - ./frontend/public:/app/public volumes: pgdata: