Commit 68332329 authored by ale's avatar ale

Add rules for missing ACME certificates

parent e242d00c
groups:
- name: roles/prometheus/files/rules/alerts_acme.conf
rules:
- alert: CertMissing
expr: cn:cert_ok < 1
for: 3d
labels:
scope: global
annotations:
summary: 'Missing certificate for {{$labels.cn}}'
description: 'The ACME automation could not generate a valid certificate for the domain "{{$labels.cn}}" for 3 days.'
groups:
- name: roles/prometheus/files/rules/rules_acme.conf
rules:
- record: cn:cert_ok
expr: max(cert_ok) by (cn)
......@@ -2,12 +2,10 @@ groups:
- name: roles/prometheus/files/rules/rules_cpu.conf
rules:
- record: instance:node_cpus:count
expr: count(node_cpu{mode="idle"}) WITHOUT (cpu, mode)
- record: instance_cpu:node_cpu_not_idle:rate5m
expr: sum(rate(node_cpu{mode!="idle"}[5m])) WITHOUT (mode)
expr: count(node_cpu{mode="idle"}) without (cpu, mode)
- record: instance_mode:node_cpu:rate5m
expr: sum(rate(node_cpu[5m])) WITHOUT (cpu)
expr: sum(rate(node_cpu[5m])) without (cpu)
- record: instance_utilization:node_cpu:rate5m
expr: sum(rate(node_cpu{mode!="idle"}[5m])) WITHOUT (mode, cpu)
expr: sum(rate(node_cpu{mode!="idle"}[5m])) without (mode, cpu)
- record: instance_utilization:rate5m
expr: instance_utilization:node_cpu:rate5m / instance:node_cpus:count
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment