diff --git a/library/common/1.0.0/templates/class/_rbac.tpl b/library/common/1.0.0/templates/class/_rbac.tpl index 8d0f88c49b..dd47e68004 100644 --- a/library/common/1.0.0/templates/class/_rbac.tpl +++ b/library/common/1.0.0/templates/class/_rbac.tpl @@ -4,6 +4,8 @@ {{- $rbacValues := .rbac -}} {{- $root := .root -}} + {{- $rbacValues = fromYaml (tpl ($rbacValues | toYaml) $root) -}} + {{- $saName := include "ix.v1.common.names.serviceAccountName" $root -}} {{- $rbacName := include "ix.v1.common.names.rbac" (dict "root" $root "rbacValues" $rbacValues) -}} @@ -62,16 +64,16 @@ rules: {{- if eq . "" }} - "" {{- else }} - - {{ tpl . $root | quote }} + - {{ . | quote }} {{- end }} {{- end }} resources: {{- range .resources }} - - {{ tpl . $root | quote }} + - {{ . | quote }} {{- end }} verbs: {{- range .verbs }} - - {{ tpl . $root | quote }} + - {{ . | quote }} {{- end }} {{- end }} {{- end }} @@ -104,9 +106,9 @@ subjects: namespace: {{ $root.Release.Namespace }} {{- with $rbacValues.subjects -}} {{- range . }} - - kind: {{ tpl (required " cannot be empty in RBAC subjects." .kind) $root | quote }} - name: {{ tpl (required " cannot be empty in RBAC subjects." .name) $root | quote }} - apiGroup: {{ tpl (required " cannot be empty in RBAC subjects." .apiGroup) $root | quote }} + - kind: {{ required " cannot be empty in RBAC subjects." .kind | quote }} + name: {{ required " cannot be empty in RBAC subjects." .name | quote }} + apiGroup: {{ required " cannot be empty in RBAC subjects." .apiGroup | quote }} {{- end }} {{- end -}} {{- end -}} diff --git a/library/common/1.0.0/templates/lib/container/env/_env.tpl b/library/common/1.0.0/templates/lib/container/env/_env.tpl index 9abb1ef8d0..444895222c 100644 --- a/library/common/1.0.0/templates/lib/container/env/_env.tpl +++ b/library/common/1.0.0/templates/lib/container/env/_env.tpl @@ -7,7 +7,7 @@ {{- $containerName := .containerName -}} {{- if $envs -}} - {{- $envs := fromYaml (tpl ($envs | toYaml) $root) -}} + {{- $envs = fromYaml (tpl ($envs | toYaml) $root) -}} {{- end -}} {{- $dupeCheck := dict -}} diff --git a/library/common/1.0.0/templates/lib/container/env/_envList.tpl b/library/common/1.0.0/templates/lib/container/env/_envList.tpl index 5039e72f7e..98f80e7951 100644 --- a/library/common/1.0.0/templates/lib/container/env/_envList.tpl +++ b/library/common/1.0.0/templates/lib/container/env/_envList.tpl @@ -7,7 +7,7 @@ {{- $root := .root -}} {{- if $envList -}} - {{- $envList := fromYaml (tpl ($envList | toYaml) $root) -}} + {{- $envList = fromYaml (tpl ($envList | toYaml) $root) -}} {{- end -}} {{- $dupeCheck := dict -}} diff --git a/library/common/1.0.0/templates/lib/job/_jobPod.tpl b/library/common/1.0.0/templates/lib/job/_jobPod.tpl index a90fde4aec..fade957678 100644 --- a/library/common/1.0.0/templates/lib/job/_jobPod.tpl +++ b/library/common/1.0.0/templates/lib/job/_jobPod.tpl @@ -4,7 +4,7 @@ {{- $values := .values -}} {{- $inherit := "inherit" -}} -{{- $values := fromYaml (tpl ($values | toYaml) $root) -}} +{{- $values = fromYaml (tpl ($values | toYaml) $root) -}} {{/* Prepare values */}} {{- $saName := "" -}}