weaveworks / grafanalib

Python library for building Grafana dashboards
Apache License 2.0
1.84k stars 305 forks source link

Discussion: Tying grafanalib to CDKTF #552

Open DontWanna1 opened 1 year ago

DontWanna1 commented 1 year ago

Please shut me down if this is an inappropriate request/means of communication.

I am currently struggling to identify the most future-proof means to deploy a grafana stack.

Terrafom/CDKTF with their official grafana-provider appears promising, safe for the poor handling of models in their alerts. Unfortunately they have no solution for dashboards creation yet, requiring a full/native json.

Grafonnet has lost its appeal.

I would very much like to discuss some ideas on how to weave CDKTF and your dashboard creation together.

JDuskey commented 1 year ago

I think this is an interesting concept, however it seems at this point the purpose of this package is to be "deployment mode agnostic". By generating raw json you can pass to any number of tools.

What kind of integration with CDKTF are you thinking? Maybe a separate generation module for outputting in a format more friendly for CDKTF? Would love to discuss.

DontWanna1 commented 1 year ago

Thank you for your reply, I am a little out of depth by now, as I had to shelf the work due to another project,

In essence: I wish to deploy grafana dashboards as code.

CDKTF allows me to basically "program jsons" to deploy including the complicated alerts. However, to add the dashboards I have to use another lib, extract the created json an plug it in the json-field of cdktf.

As I understand the provider idea of terraform and cdktf, grafana is in full control of the library and could "easily" provide a solution that allows the "programming" of the entire stack, without resorting to auxiliary libs, that do just that.

Again, sorry if I am unclear. I would very much like to restart work on that