[stable/grafana] Fix "&" in dashboards URL (#22189)

Signed-off-by: Andrey Voronkov <voronkovaa@gmail.com>
This commit is contained in:
Andrey Voronkov
2020-04-30 06:06:17 -07:00
committed by GitHub
parent 226ea86895
commit 4b261d5301
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
apiVersion: v1
name: grafana
version: 5.0.19
version: 5.0.20
appVersion: 6.7.3
kubeVersion: "^1.8.0-0"
description: The leading tool for querying and visualizing time series and metrics.
+2 -2
View File
@@ -61,8 +61,8 @@ data:
-H "Accept: application/json" \
-H "Content-Type: application/json;charset=UTF-8" \
{{ end }}
{{- if $value.url -}}{{ $value.url }}{{- else -}} https://grafana.com/api/dashboards/{{ $value.gnetId }}/revisions/{{- if $value.revision -}}{{ $value.revision }}{{- else -}}1{{- end -}}/download{{- end -}}{{ if $value.datasource }}| sed 's|\"datasource\": *\"\$[^,]*|\"datasource\": \"{{ $value.datasource }}\"|g'{{ end }}{{- if $value.b64content -}} | base64 -d {{- end -}} \
> /var/lib/grafana/dashboards/{{ $provider }}/{{ $key }}.json
{{- if $value.url -}}"{{ $value.url }}"{{- else -}}"https://grafana.com/api/dashboards/{{ $value.gnetId }}/revisions/{{- if $value.revision -}}{{ $value.revision }}{{- else -}}1{{- end -}}/download"{{- end -}}{{ if $value.datasource }} | sed 's|\"datasource\": *\"\$[^,]*|\"datasource\": \"{{ $value.datasource }}\"|g'{{ end }}{{- if $value.b64content -}} | base64 -d {{- end -}} \
> "/var/lib/grafana/dashboards/{{ $provider }}/{{ $key }}.json"
{{- end -}}
{{- end }}
{{- end }}