argocd-helm/charts/argo-cd/templates/redis/serviceaccount.yaml
Marco Kilchhofer 62699ffc82
fix(argo-cd): Add ServiceAccount for redis (#828)
* Add ability to create ServiceAccount for redis

Signed-off-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>

* Use correct default for ServiceAccounts in _helpers.tpl

Signed-off-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>

* Bump version and update changelog

Signed-off-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>
2021-07-12 13:06:50 +02:00

15 lines
615 B
YAML

{{- if and .Values.redis.enabled .Values.redis.serviceAccount.create }}
apiVersion: v1
kind: ServiceAccount
automountServiceAccountToken: {{ .Values.redis.serviceAccount.automountServiceAccountToken }}
metadata:
name: {{ template "argo-cd.redisServiceAccountName" . }}
{{- if .Values.redis.serviceAccount.annotations }}
annotations:
{{- range $key, $value := .Values.redis.serviceAccount.annotations }}
{{ $key }}: {{ $value | quote }}
{{- end }}
{{- end }}
labels:
{{- include "argo-cd.labels" (dict "context" . "component" .Values.redis.name "name" .Values.redis.name) | nindent 4 }}
{{- end }}