{{- if .Values.serviceAccount.create }}
apiVersion: v1
kind: ServiceAccount
metadata:
  name: {{ template "k8s-spot-rescheduler.serviceAccountName" . }}
  labels:
    app: {{ template "k8s-spot-rescheduler.name" . }}
    chart: {{ template "k8s-spot-rescheduler.chart" . }}
    release: {{ .Release.Name }}
    heritage: {{ .Release.Service }}
{{- end }}
