Skip to content
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

Creating Grafana-Datasource in Openshift 4.4.10 leaves json values in configmap empty #268

Closed
rbeckerpf opened this issue Sep 9, 2020 · 3 comments

Comments

@rbeckerpf
Copy link

rbeckerpf commented Sep 9, 2020

Hi,
I have the following problem: I have installed Grafana with integr8ly Version 3.5.0 (grafana-operator) in Openshift4.4.10. Everything works fine! But when I try to install a Grafana-Datasource to bind AZURE the configmap "grafana-datasources" has emtpy json values. In the custom resource definition the yaml values are still present! I using this yaml file:
apiVersion: integreatly.org/v1alpha1
kind: GrafanaDataSource
metadata:
name: ciot
namespace: grafana
spec:
datasources:
- access: proxy
editable: true
secureJsonData:
clientSecret: XXXXX
name: AzureMonitoring2
url: /api/datasources/proxy/2
jsonData:
azureLogAnalyticsSameAs: true
clientId: XXXX
cloudName: azuremonitor
logAnalyticsDefaultWorkspace: XXXXXX
subscriptionId: XXXX
tenantId: XXXXXX
version: 7
type: grafana-azure-monitor-datasource
orgId: 1
name: azuremonitor.yml

This produces the following configmap (grafana-datasources):
apiVersion: 1
datasources:

  • access: proxy
    editable: true
    jsonData: {}
    name: AzureMonitoring2
    orgId: 1
    secureJsonData: {}
    type: grafana-azure-monitor-datasource
    url: /api/datasources/proxy/2
    version: 7

As you can see, the Json Data is empty. When I add the json values by hand (temp solution) all works fine.

PS: Leading spaces in the yaml files were removed in this ticket - so please ignore this ;-)
Kind regards Ralf

@pb82
Copy link
Collaborator

pb82 commented Sep 10, 2020

This is similar to #220, json fields have to be whitelisted specifically. Can you give me a list of additional fields you want to be able to add to the jsonData and secureJsonData objects? Then i'll add them to the struct in the next version.

@rbeckerpf
Copy link
Author

rbeckerpf commented Sep 10, 2020

Hi, thanks for fast reply. I need the following objects:
jsonData:
azureLogAnalyticsSameAs:
clientId:
cloudName:
logAnalyticsDefaultWorkspace:
subscriptionId:
tenantId:

And :
secureJsonData:
clientSecret:

Many Thanks in Advance
Ralf

@pb82
Copy link
Collaborator

pb82 commented Feb 16, 2021

available in v3.8.0+

@pb82 pb82 closed this as completed Feb 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants