helm: csiplugin-configmap generates invalid configuation

When generating csiconfiguration from values the config.json key gets merged with cluster-mapping.json
as the config.json toYaml element supresses a newline.

This fixes the situation where configuration is generated as shown;

```
 data:
   config.json: |-
    [{"clusterID":"....","monitors":["..."]}]cluster-mapping.json: |-
    []
```

Signed-off-by: Toby Jackson <toby@warmfusion.co.uk>
This commit is contained in:
Toby Jackson 2021-11-04 21:18:25 +00:00 committed by mergify[bot]
parent 7f13bf6c4d
commit 989905aa9f

View File

@ -12,7 +12,7 @@ metadata:
heritage: {{ .Release.Service }}
data:
config.json: |-
{{ toJson .Values.csiConfig | indent 4 -}}
{{ toJson .Values.csiConfig | indent 4 }}
cluster-mapping.json: |-
{{ toJson .Values.csiMapping | indent 4 -}}
{{ toJson .Values.csiMapping | indent 4 }}
{{- end }}