github.com/verrazzano/verrazzano@v1.7.0/platform-operator/thirdparty/charts/thanos/templates/prometheusrule.yaml (about)

     1  {{- if and .Values.metrics.enabled .Values.metrics.prometheusRule.enabled .Values.metrics.prometheusRule.groups ( .Capabilities.APIVersions.Has "monitoring.coreos.com/v1" ) }}
     2  apiVersion: monitoring.coreos.com/v1
     3  kind: PrometheusRule
     4  metadata:
     5    name: {{ template "common.names.fullname" . }}
     6    namespace: {{ default .Release.Namespace .Values.metrics.prometheusRule.namespace | quote }}
     7    labels: {{- include "common.labels.standard" . | nindent 4 }}
     8      {{- if .Values.metrics.prometheusRule.additionalLabels }}
     9      {{- include "common.tplvalues.render" (dict "value" .Values.metrics.prometheusRule.additionalLabels "context" $) | nindent 4 }}
    10      {{- end }}
    11      {{- if .Values.commonLabels }}
    12      {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }}
    13      {{- end }}
    14    {{- if .Values.commonAnnotations }}
    15    annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
    16    {{- end }}
    17  spec:
    18    groups: {{- include "common.tplvalues.render" ( dict "value" .Values.metrics.prometheusRule.groups "context" $ ) | nindent 2 }}
    19  {{- end }}