{{- if and (not .Values.kubecostModel.plugins.existingCustomSecret.enabled) .Values.kubecostModel.plugins.enabled }} apiVersion: v1 kind: Secret metadata: name: {{ .Values.kubecostModel.plugins.secretName }} labels: {{ include "cost-analyzer.commonLabels" . | nindent 4 }} data: {{- range $key, $config := .Values.kubecostModel.plugins.configs }} {{ $key }}_config.json: {{ $config | b64enc | indent 4}} {{- end }} {{- end }}