mirror of
https://github.com/helm/charts.git
synced 2026-08-23 22:37:45 +00:00
* [stable/prometheus-operator] namespace override Signed-off-by: yoninl2 <yong.jiang1@hp.com> * bump chart version Signed-off-by: Jeremy <yong.jiang1@hp.com> * revert changes in hack folder Signed-off-by: Jeremy <yong.jiang1@hp.com> * [stable/prometheus-operator]fix template inside range Signed-off-by: jeremy <yong.jiang1@hp.com> * [stable/prometheus-operator]bump up version Signed-off-by: jeremy <yong.jiang1@hp.com>
41 lines
1.4 KiB
YAML
41 lines
1.4 KiB
YAML
{{- if or .Values.additionalPrometheusRules .Values.additionalPrometheusRulesMap}}
|
|
apiVersion: v1
|
|
kind: List
|
|
items:
|
|
{{- if .Values.additionalPrometheusRulesMap }}
|
|
{{- range $prometheusRuleName, $prometheusRule := .Values.additionalPrometheusRulesMap }}
|
|
- apiVersion: monitoring.coreos.com/v1
|
|
kind: PrometheusRule
|
|
metadata:
|
|
name: {{ template "prometheus-operator.name" $ }}-{{ $prometheusRuleName }}
|
|
namespace: {{ template "prometheus-operator.namespace" $ }}
|
|
labels:
|
|
app: {{ template "prometheus-operator.name" $ }}
|
|
{{ include "prometheus-operator.labels" $ | indent 8 }}
|
|
{{- if $prometheusRule.additionalLabels }}
|
|
{{ toYaml $prometheusRule.additionalLabels | indent 8 }}
|
|
{{- end }}
|
|
spec:
|
|
groups:
|
|
{{ toYaml $prometheusRule.groups| indent 8 }}
|
|
{{- end }}
|
|
{{- else }}
|
|
{{- range .Values.additionalPrometheusRules }}
|
|
- apiVersion: monitoring.coreos.com/v1
|
|
kind: PrometheusRule
|
|
metadata:
|
|
name: {{ template "prometheus-operator.name" $ }}-{{ .name }}
|
|
namespace: {{ template "prometheus-operator.namespace" $ }}
|
|
labels:
|
|
app: {{ template "prometheus-operator.name" $ }}
|
|
{{ include "prometheus-operator.labels" $ | indent 8 }}
|
|
{{- if .additionalLabels }}
|
|
{{ toYaml .additionalLabels | indent 8 }}
|
|
{{- end }}
|
|
spec:
|
|
groups:
|
|
{{ toYaml .groups| indent 8 }}
|
|
{{- end }}
|
|
{{- end }}
|
|
{{- end }}
|