Unable to inport dashboards with file type - Getting empty file inside grafna

Hi, I’m trying to import file dashboard with helm, but I’m getting this error:
cant import dashboard with file type, getting this error:

t=2020-03-26T10:58:02+0000 lvl=eror msg="failed to load dashboard from " logger=provisioning.dashboard type=file name=default file=/var/lib/grafana/dashboards/default/kubernetes-dashboard.json error=EOF

this is my install command:
helm install grafana stable/grafana \ -f HDIR/grafana/values.yaml \ --namespace grafana \ --set persistence.storageClassName="gp2" \ --set adminPassword='EKS!sAWSome' \ --set datasources."datasources\.yaml".apiVersion=1 \ --set datasources."datasources\.yaml".datasources[0].name=Prometheus \ --set datasources."datasources\.yaml".datasources[0].type=prometheus \ --set datasources."datasources\.yaml".datasources[0].url=http://prometheus-server.prometheus.svc.cluster.local \ --set datasources."datasources\.yaml".datasources[0].access=proxy \ --set datasources."datasources\.yaml".datasources[0].isDefault=true \ --set service.type=LoadBalancer \ --set service.loadBalancerSourceRanges={"{cidr}"}

values yaml:
dashboardProviders: dashboardproviders.yaml: apiVersion: 1 providers: - name: ‘default’ orgId: 1 folder: ‘’ type: file disableDeletion: false editable: true options: path: /var/lib/grafana/dashboards/default dashboards: default: kubernetes-dashboard: file: /home/ec2-user/aws-kube/test/test.json

maybe is something with the json location? I also try to put it near the values.yaml file.
in the helm\ grafana doc they saide to put the json in: “This is a path to a file inside the dashboards directory inside the chart directory”
what is the location, I couldn’t figure it out

1 Like