prometheus-community / helm-charts

Prometheus community Helm charts
Apache License 2.0
5.17k stars 5.04k forks source link

[kube-prometheus-stack] Selectively enable Default Grafana Dashboards and allow annotations #3160

Open martinrw opened 1 year ago

martinrw commented 1 year ago

Is your feature request related to a problem ?

I would like to be able choose which default dashboards to enable for grafana and have the ability to add annotations to them so that I can place them into specific folders.

Describe the solution you'd like.

For it to work selectively it would look somewhat similar to the default alert manager rules which are enabled like this:

defaultRules:
  create: true
  rules:
    alertmanager: true
    etcd: true
    configReloaders: false
    general: true

We could potentially take it one step further and then allow custom annotations for each one, in the end it would be enabled something like this:

defaultDashboards:
  create: true
  dashboards: 
    kubernetes_api_server:
      enabled: true
      annotations:
        - k8s-sidecar-target-directory: /tmp/dashboards/Kubernetes
    kubernetes_compute_resources_pod:
      enabled: true
      annotations:
        - k8s-sidecar-target-directory: /tmp/dashboards/Kubernetes

If you didn't specify an annotation it can just be set to {} or just not included at all

Describe alternatives you've considered.

none, I don't see any other approach at the moment other than copying the dashboard code and deploying them separately

Additional context.

No response

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Any further update will cause the issue/pull request to no longer be considered stale. Thank you for your contributions.

banschikovde commented 1 year ago

@martinrw FYI

martinrw commented 1 year ago

Thanks for commenting. I think this should remain open as I believe there is some value to this feature

jeremych1000 commented 1 year ago

Would love this as well - currently everything gets deployed into the 'General' folder.

wonderphil commented 1 year ago

Same here, would be nice to be able to clean up and set a better folder layout suited to our orgs needs!

bsgrigorov commented 1 year ago

+1 on this would love yo have it!

itswl commented 1 year ago

+1

sonykphilip commented 1 year ago

+1 for this. Is there currently a way to at least customize the default 'General' to anything else now for all of them?

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Any further update will cause the issue/pull request to no longer be considered stale. Thank you for your contributions.

martinrw commented 1 year ago

Commenting to un-stale

korewaChino commented 9 months ago

+1 for this, please do not ignore this

OT: https://fvsch.com/stale-bots

dehimb commented 6 months ago

+1 for annotations

jmischler72 commented 5 months ago

+1, it would be useful to add annotations

abrahamdevops commented 3 months ago

+1, hope it will be added

jpicara commented 2 months ago

+1, this will be very useful for all of us.

jhuspek commented 1 month ago

+1 we would like to see it too

marcoldp commented 6 days ago

+1 here too. I can give it a go at implementing it by adding an extra variable per dashboard to be added on the chart, should be quite an easy fix I think