forked from billimek/k8s-gitops
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathupsc.yaml
37 lines (37 loc) · 1009 Bytes
/
upsc.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
---
apiVersion: monitoring.coreos.com/v1
kind: PrometheusRule
metadata:
labels:
prometheus: k8s
role: alert-rules
name: upsc-rules
namespace: monitoring
spec:
groups:
- name: upsc.rules
rules:
- alert: UPS5MinutesRemain
annotations:
description: UPS almost depleted
summary: UPS {{$labels.instance}} has less than 5 minutes of battery left
expr: upsc_battery_runtime/60 < 5
for: 30s
labels:
severity: critical
- alert: UPS10MinutesRemain
annotations:
description: UPS almost depleted
summary: UPS {{$labels.instance}} has less than 10 minutes of battery left
expr: upsc_battery_runtime/60 < 10
for: 30s
labels:
severity: critical
# - alert: UPSOnBattery
# annotations:
# description: UPS is running on its battery
# summary: UPS {{$labels.instance}} is running on batteries
# expr: TBD > 0
# for: 5m
# labels:
# severity: critical