services: backend: build: context: ./backend dockerfile: Dockerfile container_name: talk-talk-backend ports: - "8765:8765" environment: - ENVIRONMENT=production env_file: - ./backend/.env restart: unless-stopped healthcheck: test: ["CMD", "python", "-c", "import httpx; httpx.get('http://localhost:8765/health')"] interval: 30s timeout: 10s retries: 3 start_period: 10s # Optional: Add nginx reverse proxy for production # nginx: # image: nginx:alpine # container_name: talk-talk-nginx # ports: # - "80:80" # - "443:443" # volumes: # - ./nginx.conf:/etc/nginx/nginx.conf:ro # depends_on: # - backend # restart: unless-stopped networks: default: name: talk-talk-network