Dependency Mixin: permit null value to be resolved
This PS udpate the dependency mixin function to permit cases where the mixin is disabled by passing a null value as the key to use for resolution. Change-Id: Idcade7eebed317852b70392431ed02a352241c9b Signed-off-by: Pete Birley <pete@port.direct>
This commit is contained in:
parent
b0c34c4468
commit
655f171a7a
@ -21,7 +21,11 @@ limitations under the License.
|
||||
{{- if $dependencyMixinParam -}}
|
||||
{{- $_ := set $envAll.Values "pod_dependency" dict -}}
|
||||
{{- if kindIs "string" $dependencyMixinParam }}
|
||||
{{- if ( index $envAll.Values.dependencies.dynamic.targeted $dependencyMixinParam ) }}
|
||||
{{- $_ := include "helm-toolkit.utils.merge" (tuple $envAll.Values.pod_dependency ( index $envAll.Values.dependencies.static $dependencyKey ) ( index $envAll.Values.dependencies.dynamic.targeted $dependencyMixinParam $dependencyKey ) ) -}}
|
||||
{{- else }}
|
||||
{{- $_ := set $envAll.Values "pod_dependency" ( index $envAll.Values.dependencies.static $dependencyKey ) }}
|
||||
{{- end }}
|
||||
{{- else if kindIs "slice" $dependencyMixinParam }}
|
||||
{{- range $k, $v := $dependencyMixinParam -}}
|
||||
{{- if not $envAll.Values.__deps }}{{- $_ := set $envAll.Values "__deps" ( index $envAll.Values.dependencies.static $dependencyKey ) }}{{- end }}
|
||||
|
Loading…
Reference in New Issue
Block a user