@@ -24,6 +24,8 @@ local kp = (import 'kube-prometheus/main.libsonnet') + {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
// Enable self-scraping so Prometheus will automatically scrape its own /metrics endpoint
|
||||||
|
selfScrape: true,
|
||||||
// Set a ServiceMonitor selector that matches the Prometheus service's labels
|
// Set a ServiceMonitor selector that matches the Prometheus service's labels
|
||||||
serviceMonitorSelector: {
|
serviceMonitorSelector: {
|
||||||
matchLabels: {
|
matchLabels: {
|
||||||
|
|||||||
@@ -46,6 +46,7 @@ spec:
|
|||||||
fsGroup: 2000
|
fsGroup: 2000
|
||||||
runAsNonRoot: true
|
runAsNonRoot: true
|
||||||
runAsUser: 1000
|
runAsUser: 1000
|
||||||
|
selfScrape: true
|
||||||
serviceAccountName: prometheus-k8s
|
serviceAccountName: prometheus-k8s
|
||||||
serviceMonitorNamespaceSelector: {}
|
serviceMonitorNamespaceSelector: {}
|
||||||
serviceMonitorSelector:
|
serviceMonitorSelector:
|
||||||
|
|||||||
Reference in New Issue
Block a user