itamae/cookbooks/prometheus/files/etc/prometheus.d/alerts/filestat.yml

13 lines
333 B
YAML

groups:
- name: filestat
rules:
- alert: RebootRequired
expr: file_glob_match_number{pattern="/var/run/reboot-required"} > 0
for: 24h
labels:
severity: warning
annotations:
summary: "Instance {{ $labels.instance }} requires rebooting."
description: "{{ $labels.instance }} requires rebooting."