# Cloudflare Tunnel Configuration
# Place this file at: /etc/cloudflared/config.yml

tunnel: <YOUR_TUNNEL_ID>
credentials-file: /etc/cloudflared/<YOUR_TUNNEL_ID>.json

# Ingress rules
ingress:
  # Main domain - API and Frontend
  - hostname: explorer.d-bis.org
    service: http://localhost:80
    originRequest:
      noHappyEyeballs: true
      connectTimeout: 30s
      tcpKeepAlive: 30s
      keepAliveTimeout: 90s
      keepAliveConnections: 100

  # WWW redirect handled by Cloudflare
  - hostname: www.explorer.d-bis.org
    service: http://localhost:80

  # Catch-all rule
  - service: http_status:404

# Metrics (optional)
metrics: 0.0.0.0:9090

# Logging
loglevel: info

