Collectd operator utilties
[demo.git] / vnfs / DAaaS / deploy / operator / charts / prometheus-operator / templates / prometheus / rules / kube-prometheus-node-alerting.rules.yaml
1 # Generated from 'kube-prometheus-node-alerting.rules' 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.kubePrometheusNodeAlerting }}
5 apiVersion: {{ printf "%s/v1" (.Values.prometheusOperator.crdApiGroup | default "monitoring.coreos.com") }}
6 kind: PrometheusRule
7 metadata:
8   name: {{ printf "%s-%s" (include "prometheus-operator.fullname" .) "kube-prometheus-node-alerting.rules" | trunc 63 | trimSuffix "-" }}
9   labels:
10     app: {{ template "prometheus-operator.name" . }}
11 {{ include "prometheus-operator.labels" . | indent 4 }}
12 {{- if .Values.defaultRules.labels }}
13 {{ toYaml .Values.defaultRules.labels | indent 4 }}
14 {{- end }}
15 {{- if .Values.defaultRules.annotations }}
16   annotations:
17 {{ toYaml .Values.defaultRules.annotations | indent 4 }}
18 {{- end }}
19 spec:
20   groups:
21   - name: kube-prometheus-node-alerting.rules
22     rules:
23     - alert: NodeDiskRunningFull
24       annotations:
25         message: Device {{`{{ $labels.device }}`}} of node-exporter {{`{{ $labels.namespace }}`}}/{{`{{ $labels.pod }}`}} will be full within the next 24 hours.
26       expr: '(node:node_filesystem_usage: > 0.85) and (predict_linear(node:node_filesystem_avail:[6h], 3600 * 24) < 0)'
27       for: 30m
28       labels:
29         severity: warning
30     - alert: NodeDiskRunningFull
31       annotations:
32         message: Device {{`{{ $labels.device }}`}} of node-exporter {{`{{ $labels.namespace }}`}}/{{`{{ $labels.pod }}`}} will be full within the next 2 hours.
33       expr: '(node:node_filesystem_usage: > 0.85) and (predict_linear(node:node_filesystem_avail:[30m], 3600 * 2) < 0)'
34       for: 10m
35       labels:
36         severity: critical
37 {{- end }}