-
Notifications
You must be signed in to change notification settings - Fork 397
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
GrafanaDashboard should support substitution from GrafanaDatasource name #1684
Comments
We discussed this issue in our weekly sync meeting and in our opinion, this does not fix the issue of it being error-prone to paste the data source name. Instead of pasting the name, you are now pasting the resource name & namespace (which is more opportunity to introduce errors). We do not maintain an admission webhook that could prevent invalid manifests from being created, so the best you'd get is an error in the Does this prevent you from using the Grafana Operator or is it mostly a usability issue? |
@theSuess Hi! Thanks for interest in the issue. As I see there is two workflow:
It is another drop that stops me from using Grafana Operator as I don't feel it mature enough. I am investigating it's advantages and possibilities and to be honest - I see a great potential, so I'd like to have a turn-key solution for managing grafana instances. Also I want to mention that main purpose of operator (from my POV) would be serving single instance grafana configuration, rather than supporting multiple grafana instances, but we are considering the latter because of the lack of user access controls in open source version of grafana. |
Thanks for the elaboration, I now see where you're coming from. We'll soon implement configurable UIDs for all resources, including data sources. In my opinion, the cleaner solution would then be to use the UID for the data source mapping field. As an example:
Do you think this would offer the same affordances in your use case? Once the ability to set UIDs has finalized, implementing references also becomes much easier but if relying on UIDs alone is also a valid choice for you, keeping the complexity low would be our main goal |
Hi!
Like a DevOps I want to apply a bunch of Datasources against the cluster. Then I want to apply GrafanaDashboard using this datasources, but I don't want to play around the name of Datasources, rather just pointing to a Datasource namespace and name. All other work should be done by operator. I will try to explain on the example.
The current behaviour:
I am applying the datasources:
and setting their name in
spec.datasource.name
(it would be nice if it could be autogenerated).Then I am applying dashboard:
What is important here - the
inputName
is the name inside of dashboard anddatasourceName
what is known to current grafana instance. I want to emphasize that IT IS ERROR PRONE to paste the datasource name manually. So the desired spec should look like:The text was updated successfully, but these errors were encountered: