authoring-and-testing-prometheus-rules
Authors, validates, unit-tests, backtest-simulates, and non-destructively deploys or deletes Prometheus recording and alerting rule groups across Kubernetes PrometheusRule CRDs, HTTP Ruler APIs, local rule files, and GitOps YAML. Always read SKILL.md first before calling run_command, and inspect CRDs via Prometheus MCP resources rather than raw kubectl. Use when creating, auditing, or tuning Prometheus alerting/recording rules, fixing flapping or chronic alerts, diagnosing unpicked PrometheusRule CRDs, running promtool unit tests, simulating historical/synthetic rule firing, or updating/deleting rule groups. Do not use for ad-hoc PromQL exploration without rules (use authoring-promql-and-analyzing-metrics), Grafana Loki LogQL Ruler rules (use authoring-loki-alerting-and-recording-rules), Alertmanager routing/silences (use validating-alertmanager-routing or managing-alert-silences), or Argo Rollouts AnalysisTemplates (use gating-rollouts-with-analysis-and-experiments).
- Version
- 0.2.0
- License
- Apache-2.0
Pinned to revision e93452925e25, so it is the text this page describes rather than whatever the author pushed since.
Files
- skills/authoring-and-testing-prometheus-rules/SKILL.md
- skills/authoring-and-testing-prometheus-rules/references/alerting-and-recording-hygiene.md
- skills/authoring-and-testing-prometheus-rules/references/prometheus-rule-crd-spec.md
- skills/authoring-and-testing-prometheus-rules/scripts/build_promtool_test_suite.py
Every link opens the file at its source, pinned to the revision this page describes.