To import custom dashboards into Grafana using Helm, follow these steps:
- Create a new directory for your Helm chart if you haven't already done so.
- Navigate to the directory where your Helm chart is located.
- Create a new folder inside the Helm chart directory for the custom dashboards. For example, you can name it "dashboards".
- Place the JSON file(s) of your custom dashboard(s) inside the "dashboards" folder. Make sure the JSON file(s) follow the Grafana dashboard JSON format.
- Open the values.yaml file inside your Helm chart directory.
- Add the following section to the values.yaml file to configure the Grafana deployment to load custom dashboards:
<name-of-configmap> with the desired name for the ConfigMap that will be created to store the custom dashboards.
- Save the values.yaml file.
- Update the Helm chart dependencies by running the following command:
- Install or upgrade the Helm chart to apply the changes:
helm install <chart-name> <helm-chart-directory> --set dashboards.enabled=true --set dashboards.configMapName=<name-of-configmap>
<chart-name> with the desired name for your Helm release, and
<helm-chart-directory> with the path to your Helm chart directory.
- Access the Grafana web interface and go to the "Dashboards" section. You should see your custom dashboards listed there.
By following these steps, you can import custom dashboards into Grafana using Helm.