From fb8c02150dc4f44bd26a33f71e30f12e6a968d24 Mon Sep 17 00:00:00 2001 From: nakarin Date: Fri, 30 Jan 2026 14:50:40 +0700 Subject: [PATCH 1/4] change podspec template serviceAccount enable and name handling --- charts/common/templates/_podSpec.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/charts/common/templates/_podSpec.yaml b/charts/common/templates/_podSpec.yaml index f7620d5f..3614c2be 100644 --- a/charts/common/templates/_podSpec.yaml +++ b/charts/common/templates/_podSpec.yaml @@ -7,8 +7,8 @@ imagePullSecrets: {{- end }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 2 }} -{{- if .Values.serviceAccount }} -serviceAccountName: {{ .Values.serviceAccount }} +{{- if .Values.serviceAccount.create -}} +serviceAccountName: {{ .Values.serviceAccount.name }} {{- end }} initContainers: {{- range .Values.initContainers }} From e1a0b68180858cc0bc6917ee360f031241bc6a39 Mon Sep 17 00:00:00 2001 From: nakarin-s Date: Fri, 30 Jan 2026 16:54:05 +0700 Subject: [PATCH 2/4] add qoute to sa.name to remove injection vulnerability --- charts/common/templates/_podSpec.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/charts/common/templates/_podSpec.yaml b/charts/common/templates/_podSpec.yaml index 3614c2be..603711a9 100644 --- a/charts/common/templates/_podSpec.yaml +++ b/charts/common/templates/_podSpec.yaml @@ -8,7 +8,7 @@ imagePullSecrets: securityContext: {{- toYaml .Values.podSecurityContext | nindent 2 }} {{- if .Values.serviceAccount.create -}} -serviceAccountName: {{ .Values.serviceAccount.name }} +serviceAccountName: {{ .Values.serviceAccount.name | quote }} {{- end }} initContainers: {{- range .Values.initContainers }} @@ -80,4 +80,4 @@ affinity: tolerations: {{- toYaml . | nindent 2 }} {{- end }} -{{- end }} \ No newline at end of file +{{- end }} From 9bae40e8c817399b7888262715a3df52cc285001 Mon Sep 17 00:00:00 2001 From: nakarin-s Date: Fri, 30 Jan 2026 17:01:49 +0700 Subject: [PATCH 3/4] add qoute to sa.name to remove injection vulnerability From ed82fc76de8a2aa15cc86bc250428fe6ffde00d6 Mon Sep 17 00:00:00 2001 From: nakarin-s Date: Fri, 30 Jan 2026 17:02:24 +0700 Subject: [PATCH 4/4] remove white space