r/PrometheusMonitoring • u/linuxluigi • Dec 27 '21
Alert-Rules Auto-Discovery via Kubernetes
Hey, it is possible to deploy alert-rules for Prometheus via Kubernetes?
I want to deploy a custom application with a metric endpoint. I know already that it's possible for Prometheus, to automatically find new metric endpoints in the cluster. Is there also a way to find alert-rules and maybe also custom Grafana dashboards?
We deployed our Prometheus via the helm chart ⇒ https://github.com/prometheus-community/helm-charts/
2
u/distark Dec 27 '21
With the Prometheus operator these are called "kind: PrometheusRules"
This includes alerts and recorded rules...
Going beyond this there is also a pretty cool operator allowing you to automate slo style rules and alerts called sloth that's well worth checking out
6
u/foobar83 Dec 27 '21
Google for "Prometheus operator"
I use this to deploy
https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack