# GitHub ARC Controller - Base Values (New v0.8.0+ API)
# These values are shared across all environments
# Install with: helm install arc oci://ghcr.io/jeanschmidt/actions-runner-controller-charts/gha-runner-scale-set-controller

# Controller settings
replicaCount: 2

# Controller resources — sized for 40+ AutoScalingRunnerSets at high concurrency.
# Informer caches grow linearly with active runners; Go GC doubles live heap.
# At peak (thousands of concurrent runners), cache alone can exceed 1Gi.
resources:
  limits:
    cpu: "4"
    memory: 4Gi
  requests:
    cpu: "1"
    memory: 2Gi

# Logging level (debug, info, warn, error)
log:
  level: info
  format: text

# Flags for the controller
flags:
  # Update listener pods when new runner image is available
  updateStrategy: "immediate"
  # Watch namespaces (empty = all namespaces)
  watchNamespace: ""

# Service account
serviceAccount:
  create: true
  annotations: {}

# Metrics
metrics:
  controllerManagerAddr: ":8080"
  listenerAddr: ":8080"
  listenerEndpoint: "/metrics"

# Security context
securityContext:
  runAsNonRoot: true
  runAsUser: 1000

# CRITICAL: Tolerations to run on base infrastructure nodes
# The base nodes are tainted with CriticalAddonsOnly=true:NoSchedule
tolerations:
  - key: CriticalAddonsOnly
    operator: Equal
    value: "true"
    effect: NoSchedule

# Node selector (optional - can specify if base nodes have specific labels)
nodeSelector: {}
