mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-08-29 22:37:12 +02:00
The NixOS alertmanager module pipes the generated config through envsubst to inject secrets, which silently replaced the template's $i/$a variables with empty strings, so every telegram notification failed with a template parse error since Friday's deploy. Rewrite the template without variables: range + dot, define/template for the per-alert block, and an if/else split to cap a group at 5 alerts (slice errors when fewer than 5). Verified with amtool template render against post-envsubst content for both branches. Signed-off-by: Ryan Yin <xiaoyin_c@qq.com>
Monitoring & Alerting
Alert Rules & Recoding Rules
- awesome-prometheus-alerts
- Collection of Prometheus alerting rules.
- victoria-metrics-k8s-stack/files/rules
- Alert Rules & Recoding Rules used by kube-prometheus-stack.