Arindam
Arindam

Reputation: 71

unable to import a grafana dashboard from json file using the kube-prometheus-stack helm chart

I am playing around with the kube-prometheus-stack and stumbled upon an issue which I am not sure how to approach to fix.

looking at the comfigmap-dashboards.yaml (https://github.com/prometheus-community/helm-charts/blob/main/charts/kube-prometheus-stack/templates/grafana/configmap-dashboards.yaml) It seems that if I put the .json files for the different custom dashboards inside the folder dashboards-1.14, it will be automatically picked up and the config maps would be automatically created based on the number pf the json files present in the folder.

I have double checked values for the grafana enabled and grafana defaultdahsboardenable to be true.

But when I run the helm template command, I am not getting the config map/maps generated. I am trying to understand what am I doing wrong here.

Please note, if I create a configmap with the json content pasted in it and put the configmap in the dashboards-1.14 folder I am getting the configmap while I run the helm template command. But my understanding is that we need not write the configmap as it should be automatically generated from configmap-dashboard (the link that I pasted above)

Upvotes: 0

Views: 1544

Answers (1)

617m4rc
617m4rc

Reputation: 1

Put your .json files into a new folder kube-prometheus-stack/dashboards-1.14, not into the existing one kube-prometheus-stack/templates/grafana/dashboards-1.14

Upvotes: 0

Related Questions