apiVersion: v1
kind: ConfigMap
metadata:
  name: citadel-agent-config
  namespace: observability
  labels:
    app.kubernetes.io/name: citadel-agent
    app.kubernetes.io/part-of: citadel
data:
  # Agent ships logs via HTTP to partner-hosted Citadel
  CITADEL_HTTP: "true"
  CITADEL_HTTP_URL: "https://citadel-staging.orchard9.ai"

  # Log routing: agent reads these k8s labels to determine target environment
  # citadel.io/environment → target Citadel tenant ID
  # citadel.io/service     → service name tag
  CITADEL_ROUTE_LABEL_ENVIRONMENT: "citadel.io/environment"
  CITADEL_ROUTE_LABEL_SERVICE: "citadel.io/service"

  # Namespaces to collect logs from
  # rdev namespace = platform components (rdev-api, rdev-worker, claudebox)
  # projects namespace = generated project pods
  CITADEL_NAMESPACES: "rdev,projects,observability"

  # Default environment for pods without citadel.io/environment label
  # Platform pods (rdev-api, rdev-worker) route here
  CITADEL_DEFAULT_ENVIRONMENT: "rdev-platform"
