2023-03-28 10:16:38 +01:00
|
|
|
{{- $containerMode := .Values.containerMode }}
|
|
|
|
|
{{- if and (eq $containerMode.type "kubernetes") (not .Values.template.spec.serviceAccountName) }}
|
2023-01-17 14:36:04 -05:00
|
|
|
apiVersion: v1
|
|
|
|
|
kind: ServiceAccount
|
|
|
|
|
metadata:
|
2023-03-01 13:16:03 +01:00
|
|
|
name: {{ include "gha-runner-scale-set.kubeModeServiceAccountName" . }}
|
2023-01-17 14:36:04 -05:00
|
|
|
namespace: {{ .Release.Namespace }}
|
2023-10-18 20:37:39 +09:00
|
|
|
{{- if .Values.containerMode.kubernetesModeServiceAccount }}
|
|
|
|
|
{{- with .Values.containerMode.kubernetesModeServiceAccount.annotations }}
|
|
|
|
|
annotations:
|
|
|
|
|
{{- toYaml . | nindent 4 }}
|
|
|
|
|
{{- end }}
|
|
|
|
|
{{- end }}
|
2023-04-03 21:06:12 +02:00
|
|
|
finalizers:
|
|
|
|
|
- actions.github.com/cleanup-protection
|
2023-01-17 14:36:04 -05:00
|
|
|
labels:
|
2023-03-01 13:16:03 +01:00
|
|
|
{{- include "gha-runner-scale-set.labels" . | nindent 4 }}
|
2023-03-28 10:16:38 +01:00
|
|
|
{{- end }}
|