2024-05-13 15:20:21 +00:00
|
|
|
{{- define "lib.config.env" -}}
|
|
|
|
{{- range $k, $v := .Values.env }}
|
|
|
|
{{- $customName := printf "%s-%s" (include "chart.fullname" $) $k }}
|
|
|
|
---
|
|
|
|
apiVersion: v1
|
|
|
|
{{- if not $v.sensitive }}
|
|
|
|
kind: ConfigMap
|
|
|
|
{{- include "lib.metadata" (dict "Context" $ "customName" $customName)}}
|
|
|
|
data:
|
|
|
|
{{- else }}
|
|
|
|
kind: Secret
|
|
|
|
{{- include "lib.metadata" (dict "Context" $ "customName" $customName)}}
|
|
|
|
stringData:
|
|
|
|
{{- end }}
|
2024-07-15 05:47:25 +00:00
|
|
|
{{- range $k, $v := $v.data }}
|
|
|
|
{{ $k }}: {{ $v | quote }}
|
2024-05-13 15:20:21 +00:00
|
|
|
{{- end }}
|
|
|
|
{{- end }}
|
|
|
|
{{- end -}}
|
|
|
|
|