apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
  name: arc-controller
  namespace: monitoring
  labels:
    app.kubernetes.io/part-of: osdc-monitoring
spec:
  namespaceSelector:
    matchNames:
      - arc-systems
  selector:
    matchLabels:
      app.kubernetes.io/name: gha-rs-controller
  endpoints:
    - port: metrics
      interval: 60s
      metricRelabelings:
        # Keep only ARC operational metrics and reconcile errors — drop everything else
        - action: keep
          sourceLabels: [__name__]
          regex: "gha_controller_.*|controller_runtime_reconcile_errors_total"
