apiVersion: monitoring.coreos.com/v1 kind: PodMonitor metadata: name: flux-system-monitoring namespace: flux-system labels: app.kubernetes.io/part-of: flux annotations: monitoring.edge.ncr.com/allowed-metrics: | controller_runtime_reconcile_time_seconds_bucket controller_runtime_reconcile_time_seconds_count controller_runtime_reconcile_time_seconds_sum controller_runtime_reconcile_total go_info go_memstats_alloc_bytes go_memstats_alloc_bytes_total gotk_reconcile_condition gotk_reconcile_duration_seconds_bucket gotk_reconcile_duration_seconds_count gotk_reconcile_duration_seconds_sum process_cpu_seconds_total process_start_time_seconds process_virtual_memory_bytes rest_client_requests_total workqueue_longest_running_processor_seconds spec: selector: matchExpressions: - key: app operator: In values: - helm-controller - source-controller - kustomize-controller - notification-controller - image-automation-controller - image-reflector-controller jobLabel: app.kubernetes.io/name podMetricsEndpoints: - port: http-prom interval: 60s path: /metrics relabelings: - action: keep regex: "true" sourceLabels: - __meta_kubernetes_pod_annotation_prometheus_io_scrape - action: replace regex: (.+) sourceLabels: - __meta_kubernetes_pod_annotation_prometheus_io_path targetLabel: __metrics_path__ - action: replace regex: ([^:]+)(?::\d+)?;(\d+) replacement: $1:$2 sourceLabels: - __address__ - __meta_kubernetes_pod_annotation_prometheus_io_port targetLabel: __address__ - action: labelmap regex: __meta_kubernetes_pod_label_(.+) - action: replace sourceLabels: - __meta_kubernetes_namespace targetLabel: namespace - action: replace sourceLabels: - __meta_kubernetes_pod_name targetLabel: pod