k8s-deployment/charts/roles/templates/sa.yaml

21 lines
439 B
YAML
Raw Normal View History

2024-10-10 05:25:16 +00:00
{{- if .Values.sa }}
{{- range $sa := .Values.roles }}
---
apiVersion: v1
kind: ServiceAccount
metadata:
name: {{ $sa.name }}
namespace: {{ $sa.namespace }}
labels:
{{- include "roles.labels" $ | nindent 4 }}
{{- with $sa.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with $sa.annotations}}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
automountServiceAccountToken: true
{{- end }}
{{- end }}