version: '3.8' services: santa-hat-api: build: . container_name: santa-hat-api ports: - "8000:8000" volumes: # Mount static folder to allow updating santa_hat.png without rebuilding - ./static:/app/static:ro environment: - PYTHONUNBUFFERED=1 env_file: - .env # Load environment variables from .env file (optional) restart: unless-stopped healthcheck: test: ["CMD", "python", "-c", "import requests; requests.get('http://localhost:8000/health')"] interval: 30s timeout: 3s retries: 3 start_period: 5s