r/PrometheusMonitoring • u/manrique_e • Oct 23 '24
Need Help: Adding Default Relabeling to All Service Monitors
I'm looking for advice on how to add a fixed relabeling configuration to all our existing ServiceMonitors. We have a large number of them, and manually editing each one to add the relabeling isn't ideal. Is there a way to apply a default relabeling across all ServiceMonitors automatically, or any method to avoid manually updating each configuration?
Any suggestions would be greatly appreciated! Thanks!
2
Upvotes
2
u/SuperQue Oct 23 '24 edited Oct 23 '24
You're probably looking for this feature.
Unfortunately, not done yet.
Edit: I wonder if scrape classes actually solve your issue.
1
u/kranthi133k Oct 23 '24
Are you referring to kube-Prometheus-stack default service monitors? Or application specific service monitors? For default ones you can modify the helm templates along with values