| services: | |
| # Service 1: The Brain (FastAPI) | |
| api: | |
| build: | |
| context: . | |
| dockerfile: Dockerfile.api # <--- CHANGE THIS LINE (was just '.') | |
| container_name: med-gemma-api | |
| ports: | |
| - "8000:80" | |
| env_file: | |
| - .env | |
| environment: | |
| - HF_TOKEN=${HF_TOKEN} | |
| # Service 2: The Face (Streamlit) | |
| web: | |
| build: ./frontend # Uses the Dockerfile in the frontend folder | |
| container_name: med-gemma-dashboard | |
| ports: | |
| - "8501:8501" # Expose Dashboard on port 8501 | |
| environment: | |
| # We talk to 'api' (the service name), not 'localhost' | |
| - API_URL=http://api:80/triage | |
| depends_on: | |
| - api # Wait for the API to start before starting the dashboard |