[common] allow the use of tpl's for envFrom (#822)
* allow the use of tpl's for envFrom * actuall this is a feature increase
This commit is contained in:
@@ -18,4 +18,4 @@ maintainers:
|
|||||||
name: common
|
name: common
|
||||||
sources: null
|
sources: null
|
||||||
type: library
|
type: library
|
||||||
version: 6.9.2
|
version: 6.10.0
|
||||||
|
|||||||
@@ -40,6 +40,10 @@
|
|||||||
secretKeyRef:
|
secretKeyRef:
|
||||||
name: {{ tpl $value.secretKeyRef.name $ | quote }}
|
name: {{ tpl $value.secretKeyRef.name $ | quote }}
|
||||||
key: {{ tpl $value.secretKeyRef.key $ | quote }}
|
key: {{ tpl $value.secretKeyRef.key $ | quote }}
|
||||||
|
{{- else if $value.configMapRef }}
|
||||||
|
configMapRef:
|
||||||
|
name: {{ tpl $value.configMapRef.name $ | quote }}
|
||||||
|
key: {{ tpl $value.configMapRef.key $ | quote }}
|
||||||
{{- else }}
|
{{- else }}
|
||||||
{{- $value | toYaml | nindent 8 }}
|
{{- $value | toYaml | nindent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
@@ -79,8 +83,16 @@
|
|||||||
{{- end }}
|
{{- end }}
|
||||||
{{- if or .Values.envFrom .Values.secret }}
|
{{- if or .Values.envFrom .Values.secret }}
|
||||||
envFrom:
|
envFrom:
|
||||||
{{- with .Values.envFrom }}
|
{{- range $key, $value := .Values.envFrom }}
|
||||||
{{- toYaml . | nindent 4 }}
|
{{- if $value.secretKeyRef }}
|
||||||
|
- secretKeyRef:
|
||||||
|
name: {{ tpl $value.secretKeyRef.name $ | quote }}
|
||||||
|
{{- else if $value.configMapRef }}
|
||||||
|
- configMapRef:
|
||||||
|
name: {{ tpl $value.configMapRef.name $ | quote }}
|
||||||
|
{- else }}
|
||||||
|
{{- toYaml $value | nindent 4 }}
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- if .Values.secret }}
|
{{- if .Values.secret }}
|
||||||
- secretRef:
|
- secretRef:
|
||||||
|
|||||||
Reference in New Issue
Block a user