Hello, I am running Grafana 10.1.4 open source, and using Helm to deploy it into Kubernetes. I would love to have my alerts & dashboards in source control. To do this I was hoping to leverage the alerts provisioning which is outlined in the documentation here.
In those docs I found a block like this:
alerting:
team1-alert-rules.yaml:
file: alerting/team1/rules.yaml
This looks like it would be a way for me to add a folder to my Helm chart and then inject those Yaml files into the Grafana system. But when I go to look at those files I find they are empty. I have tried an inline version of the same and that looks like it is working.
Another thing that I have tried was to use Helm templating to inject the file like this:
alerting:
one-alert.yaml: |-
{{ .Files.Get "one-alert.yaml" }}
But I don’t even expect this to work, as I’m using the templating in the values file, not in the template files.
I am trying to figure out what is the best way to do this. I’m looking into some of the sidecar configuration options like you see here, but if anybody has some other tips on how to have my alerts/dashboards in source control please do share!
.