# hrafn — internal fleet service. No published host port; consumers reach
# it at http://hrafn:8080 on the shared network (contract § Deployment).
services:
  hrafn:
    build: .
    image: local/hrafn:${HRAFN_TAG:-v1}
    container_name: hrafn
    restart: unless-stopped
    env_file: .env
    networks:
      - traefik-net
    # Chromium wants a larger shared-memory segment than Docker's 64MB
    # default or it crashes on some pages.
    shm_size: "1gb"
    healthcheck:
      test: ["CMD", "python", "-c",
             "import urllib.request,sys; sys.exit(0 if urllib.request.urlopen('http://127.0.0.1:8080/readyz').status==200 else 1)"]
      interval: 30s
      timeout: 5s
      retries: 3
      start_period: 20s

networks:
  traefik-net:
    external: true
