Add option to specify job label for service monitor
This commit is contained in:
parent
559690f579
commit
9d9f10ce8b
2 changed files with 5 additions and 0 deletions
|
@ -22,6 +22,9 @@ spec:
|
||||||
{{- if .Values.controller.metrics.serviceMonitor.metricRelabelings }}
|
{{- if .Values.controller.metrics.serviceMonitor.metricRelabelings }}
|
||||||
metricRelabelings: {{ toYaml .Values.controller.metrics.serviceMonitor.metricRelabelings | nindent 8 }}
|
metricRelabelings: {{ toYaml .Values.controller.metrics.serviceMonitor.metricRelabelings | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
{{- if .Values.controller.metrics.serviceMonitor.jobLabel }}
|
||||||
|
jobLabel: {{ .Values.controller.metrics.serviceMonitor.jobLabel | quote }}
|
||||||
|
{{- end }}
|
||||||
{{- if .Values.controller.metrics.serviceMonitor.namespaceSelector }}
|
{{- if .Values.controller.metrics.serviceMonitor.namespaceSelector }}
|
||||||
namespaceSelector: {{ toYaml .Values.controller.metrics.serviceMonitor.namespaceSelector | nindent 4 }}
|
namespaceSelector: {{ toYaml .Values.controller.metrics.serviceMonitor.namespaceSelector | nindent 4 }}
|
||||||
{{ else }}
|
{{ else }}
|
||||||
|
|
|
@ -523,6 +523,8 @@ controller:
|
||||||
serviceMonitor:
|
serviceMonitor:
|
||||||
enabled: false
|
enabled: false
|
||||||
additionalLabels: {}
|
additionalLabels: {}
|
||||||
|
# The label to use to retrieve the job name from.
|
||||||
|
# jobLabel: "app.kubernetes.io/name"
|
||||||
namespace: ""
|
namespace: ""
|
||||||
namespaceSelector: {}
|
namespaceSelector: {}
|
||||||
# Default: scrape .Release.Namespace only
|
# Default: scrape .Release.Namespace only
|
||||||
|
|
Loading…
Reference in a new issue