services: # ── FastAPI Backend (API mode — no GPU required) ───────────────────── backend: build: context: ./backend dockerfile: Dockerfile container_name: voicetrace-backend ports: - "8000:8000" env_file: - .env environment: # Explicitly set mode here; can be overridden in .env - MODEL_MODE=api volumes: # Mount source for hot-reload in development; remove for production - ./backend:/app restart: unless-stopped # NOTE: No GPU reservation needed — all inference is via API # ── Streamlit Frontend ───────────────────────────────────────────── streamlit: build: context: ./frontend dockerfile: Dockerfile container_name: voicetrace-streamlit ports: - "8501:8501" env_file: - .env environment: - BACKEND_URL=http://backend:8000 # These are passed from .env but explicitly listed for clarity - SUPABASE_URL=${SUPABASE_URL} - SUPABASE_ANON_KEY=${SUPABASE_ANON_KEY} - FRONTEND_URL=http://localhost:8501 depends_on: - backend restart: unless-stopped # No local volumes needed — WhisperX cache is gone