feat(prometheus): set service monitor label selector
This commit is contained in:
@@ -119,6 +119,9 @@ install: check-env
|
||||
--wait \
|
||||
-f values.yaml
|
||||
|
||||
# Label monitoring namespace to enable self-monitoring
|
||||
kubectl label namespace ${PROMETHEUS_NAMESPACE} buun.channel/enable-monitoring=true --overwrite
|
||||
|
||||
admin_password=$(just admin-password)
|
||||
|
||||
echo ""
|
||||
|
||||
@@ -60,6 +60,13 @@ prometheus:
|
||||
requests:
|
||||
storage: 50Gi
|
||||
|
||||
# ServiceMonitor selection
|
||||
# Select ServiceMonitors with release label only in namespaces with enable-monitoring label
|
||||
serviceMonitorSelectorNilUsesHelmValues: true
|
||||
serviceMonitorNamespaceSelector:
|
||||
matchLabels:
|
||||
buun.channel/enable-monitoring: "true"
|
||||
|
||||
{{- if .Env.PROMETHEUS_HOST }}
|
||||
ingress:
|
||||
enabled: true
|
||||
|
||||
Reference in New Issue
Block a user