-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Grafana folders support #72
Comments
Does this actually organize the dashboards in Grafana folders? As I understand the folder needs to be specified at the provisioner level, not at the dashboard level https://grafana.com/docs/administration/provisioning/#dashboards. |
It requires both, the provisioning configuration is used to tell grafana what directories it should look in for the dashboards. However it is required that the dashboards are placed in specific directories for that configuration to take in effect. For example current configuration is mounting the dashboards in a hardcoded directory:
The
Also we cannot pass through a composite path for the dashboard jsons as that will fail, so my hack would just allow for 1 level path to be passed through without it failing. Alternatively the path can be changed to be a variable and made easier to pass through, however that might be a breaking change for the current version so I'm not sure if that's a viable option, in one attempt I've created a new configuration in which I would pass the folder and dashboards separately but that meant I would lose all dashboards that were not configured that way. |
This there is no out of the box experience for this today, that is correct. I'd be happy to see it become a reality though, if you figure out something elegant I'd be more than happy to review and merge it :) |
I've had some time to throw together the change today. https://github.com/SebastianIoanPop/kubernetes-grafana/tree/grafana-folders/non-intrusive-attempt I still have to test it in K8s and have some concerns to address before creating the PR. I will come back in a few days to test it and create the PR :) |
Add folder support for dashboards (#72).
Hello, is there a way currently to make use of the grafana folders feature?
See:
https://grafana.com/docs/reference/dashboard_folders/
and
https://grafana.com/docs/administration/provisioning/#dashboards
I've tried a few hacks to make this work, as currently providing the configuration for dashboards with a composite path currently is not supported.
As the only limitation seems to be creating multiple folders within the container and separating the dashboards into the appropriate folders, I've tried the following:
(apply this change anywhere where it's relevant)
Which allowed the following convention to be used:
However due to changing the core vendor file, it would make keeping up to date difficult so I would prefer it if I didn't have extra maintenance should this repo be updated.
I've also faced multiple problems related to volume mounts while doing that.
My approach should be a non-breaking change, however I don't fully understand jsonnet, grafana or kubernetes so there may be implications I'm not aware of or a better and cleaner way of doing it.
Thanks!
The text was updated successfully, but these errors were encountered: