# =============================================================================
# Felhom Hub Configuration
# =============================================================================
# Location: /etc/felhom-hub/hub.yaml (or mount as ConfigMap in k8s)
#
# The hub receives health reports from customer controllers and serves
# a multi-customer overview dashboard for the operator.
# =============================================================================

# --- Authentication ---
auth:
  # Bcrypt hash for dashboard login (Viktor only)
  password_hash: ""

# --- API ---
api:
  # Bearer token required for report ingest (POST /api/v1/report)
  report_api_key: ""

# --- Notifications ---
notifications:
  resend_api_key: ""           # Resend.com API key for sending notification emails
  from_email: "monitoring@felhom.eu"  # Sender address for notification emails

# --- Data retention ---
retention:
  max_days: 90               # Keep 90 days of report history
  prune_schedule: "04:30"    # Daily prune time (Europe/Budapest)

# --- Alerting thresholds ---
alerting:
  stale_threshold: "30m"     # Customer considered stale if no report for this duration

# --- Registry / template fetching ---
registry:
  image: "gitea.dooplex.hu/admin/felhom-controller"
  username: ""               # Gitea username (for version check + template fetch)
  token: ""                  # Gitea token
  check_interval: "6h"      # How often to check for new controller versions
  template_interval: "1h"   # How often to fetch controller.yaml.example for config generation

# --- Server ---
server:
  listen: ":8080"
  data_dir: "/data"          # SQLite database location
