# helm_charts_agent-serviceaccount.yaml
{{- if .Values.agent.enabled -}}
{{- if .Values.serviceAccounts.agent.create }}
apiVersion: v1
kind: ServiceAccount
metadata:
  labels:
    app: {{ template "kiam.name" . }}
    chart: {{ template "kiam.chart" . }}
    component: "{{ .Values.agent.name }}"
    heritage: {{ .Release.Service }}
    release: {{ .Release.Name }}
  name: {{ template "kiam.serviceAccountName.agent" . }}
{{- end }}
{{- end }}