replace "define" templates with simple values now that controller.workflowNamespaces and workflow.namespace are unified into a single "range" iteration

Signed-off-by: reinvantveer <rein.van.t.veer@geodan.nl>
This commit is contained in:
reinvantveer 2021-07-12 14:29:23 +02:00
parent 447285dca3
commit 7622124536

View file

@ -1,10 +1,3 @@
{{- define "sa-base" }}
---
apiVersion: v1
kind: ServiceAccount
metadata:
{{- end }}
{{- if .Values.workflow.serviceAccount.create -}}
{{- /*
@ -26,7 +19,10 @@ metadata:
{{- end }}
{{ range $namespace := append .Values.controller.workflowNamespaces .Values.workflow.namespace | compact | uniq }}
{{ include "sa-base" . }}
---
apiVersion: v1
kind: ServiceAccount
metadata:
name: {{ $.Values.workflow.serviceAccount.name }}
namespace: {{ $namespace }}
annotations: