Skip to content

Commit 67b26e8

Browse files
committed
Update security context to allow override by cluster policy
1 parent 713c217 commit 67b26e8

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

charts/backend/templates/deployment.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ spec:
2222
{{- else }}
2323
serviceAccountName: {{ default "default" .Values.serviceAccount.name }}
2424
{{- end }}
25-
securityContext: {{ include "common.tplvalues.render" ( dict "value" .Values.securityContext "context" $ )}}
25+
{{- with .Values.securityContext }}
26+
securityContext: {{ include "common.tplvalues.render" (dict "value" . "context" $ )}}
27+
{{- end }}
2628
imagePullSecrets: {{ include "common.images.renderPullSecrets" ( dict "images" ( list .Values.image ) "context" $ ) }}
2729
containers:
2830
- name: {{ include "common.names.name" $ }}

charts/frontend/templates/deployment.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,9 @@ spec:
2020
{{- else }}
2121
serviceAccountName: {{ default "default" .Values.serviceAccount.name }}
2222
{{- end }}
23-
securityContext: {{ include "common.tplvalues.render" ( dict "value" .Values.securityContext "context" $ )}}
23+
{{- with .Values.securityContext }}
24+
securityContext: {{ include "common.tplvalues.render" (dict "value" . "context" $ )}}
25+
{{- end }}
2426
imagePullSecrets: {{ include "common.images.renderPullSecrets" ( dict "images" ( list .Values.image ) "context" $ ) }}
2527
containers:
2628
- name: {{ include "common.names.name" $ }}

0 commit comments

Comments
 (0)