services:
  web:
    # .NET 10 dropped support for Windows 10 containers (nanoserver-1809),
    # so all Dockerfiles now target Linux. Switch Docker Desktop to Linux
    # container mode before building.
    build:
      context: .
      dockerfile: Dockerfile.linux
    ports:
      - "5000:8080"
    environment:
      - ASPNETCORE_ENVIRONMENT=Production
      - AdminSettings__Password=${ADMIN_PASSWORD:?Set ADMIN_PASSWORD}
      - EmailSettings__Username=${EMAIL_USERNAME:?Set EMAIL_USERNAME}
      - EmailSettings__Password=${EMAIL_PASSWORD:?Set EMAIL_PASSWORD}
    volumes:
      - app_data:/data
    restart: unless-stopped

volumes:
  app_data:
