File tree Expand file tree Collapse file tree 4 files changed +41
-0
lines changed
Expand file tree Collapse file tree 4 files changed +41
-0
lines changed Original file line number Diff line number Diff line change @@ -13,11 +13,22 @@ namespace: opendatahub
1313# 2. Import base configuration
1414resources :
1515 - ../../default # Inherits everything from config/default/
16+ - ../../prometheus
1617 - networkpolicy.yaml
1718
1819# 3. Delete the Namespace resource (ODH operator manages it)
20+ # Add monitoring label to PodMonitor
1921patches :
2022 - path : delete-namespace.yaml
23+ - patch : |-
24+ - op: add
25+ path: /metadata/labels/opendatahub.io~1monitoring
26+ value: "true"
27+ target:
28+ group: monitoring.coreos.com
29+ version: v1
30+ kind: PodMonitor
31+ name: spark-operator-metrics-monitor
2132
2233# 4. Add ODH-specific labels
2334labels :
Original file line number Diff line number Diff line change @@ -13,11 +13,22 @@ namespace: redhat-ods-applications
1313# 2. Import base configuration
1414resources :
1515 - ../../default # Inherits everything from config/default/
16+ - ../../prometheus
1617 - networkpolicy.yaml
1718
1819# 3. Delete the Namespace resource (RHOAI operator manages it)
20+ # Add monitoring label to PodMonitor
1921patches :
2022 - path : delete-namespace.yaml
23+ - patch : |-
24+ - op: add
25+ path: /metadata/labels/opendatahub.io~1monitoring
26+ value: "true"
27+ target:
28+ group: monitoring.coreos.com
29+ version: v1
30+ kind: PodMonitor
31+ name: spark-operator-metrics-monitor
2132
2233# 4. Add RHOAI-specific labels
2334labels :
Original file line number Diff line number Diff line change 1+ apiVersion : kustomize.config.k8s.io/v1beta1
2+ kind : Kustomization
3+
4+ resources :
5+ - podmonitor.yaml
Original file line number Diff line number Diff line change 1+ apiVersion : monitoring.coreos.com/v1
2+ kind : PodMonitor
3+ metadata :
4+ name : spark-operator-metrics-monitor
5+ namespace : system
6+ spec :
7+ podMetricsEndpoints :
8+ - port : metrics
9+ path : /metrics
10+ scheme : http
11+ selector :
12+ matchLabels :
13+ app.kubernetes.io/name : spark-operator
14+ app.kubernetes.io/component : controller
You can’t perform that action at this time.
0 commit comments