1 # Generated from 'prometheus-operator' group from https://raw.githubusercontent.com/coreos/prometheus-operator/master/contrib/kube-prometheus/manifests/prometheus-rules.yaml
2 # Do not change in-place! In order to change this file first read following link:
3 # https://github.com/helm/charts/tree/master/stable/prometheus-operator/hack
4 {{- if and .Values.defaultRules.create .Values.defaultRules.rules.prometheusOperator }}
5 {{- $operatorJob := printf "%s-%s" (include "prometheus-operator.fullname" .) "operator" }}
6 {{- $namespace := .Release.Namespace }}
7 apiVersion: {{ printf "%s/v1" (.Values.prometheusOperator.crdApiGroup | default "monitoring.coreos.com") }}
10 name: {{ printf "%s-%s" (include "prometheus-operator.fullname" .) "prometheus-operator" | trunc 63 | trimSuffix "-" }}
12 app: {{ template "prometheus-operator.name" . }}
13 {{ include "prometheus-operator.labels" . | indent 4 }}
14 {{- if .Values.defaultRules.labels }}
15 {{ toYaml .Values.defaultRules.labels | indent 4 }}
17 {{- if .Values.defaultRules.annotations }}
19 {{ toYaml .Values.defaultRules.annotations | indent 4 }}
23 - name: prometheus-operator
25 - alert: PrometheusOperatorReconcileErrors
27 message: Errors while reconciling {{`{{ $labels.controller }}`}} in {{`{{ $labels.namespace }}`}} Namespace.
28 expr: rate(prometheus_operator_reconcile_errors_total{job="{{ $operatorJob }}",namespace="{{ $namespace }}"}[5m]) > 0.1
32 - alert: PrometheusOperatorNodeLookupErrors
34 message: Errors while reconciling Prometheus in {{`{{ $labels.namespace }}`}} Namespace.
35 expr: rate(prometheus_operator_node_address_lookup_errors_total{job="{{ $operatorJob }}",namespace="{{ $namespace }}"}[5m]) > 0.1