Compute-utility: Add pod/container security context
This updates the compute-utility chart to include the pod security context on the pod template. This also adds the container security context to set readOnlyRootFilesystem flag to false Change-Id: I769b75a54e4b384fb6756176026bd6f1228220c3
This commit is contained in:
parent
19e2fa9721
commit
3005b63288
|
@ -68,8 +68,7 @@ spec:
|
|||
labels:
|
||||
{{ tuple $envAll "compute" "utility" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 8 }}
|
||||
spec:
|
||||
securityContext:
|
||||
runAsUser: 65534
|
||||
{{ dict "envAll" $envAll "application" "compute" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
serviceAccountName: {{ $serviceAccountName }}
|
||||
affinity:
|
||||
{{ tuple $envAll "compute" "utility" | include "helm-toolkit.snippets.kubernetes_pod_anti_affinity" | indent 8 }}
|
||||
|
@ -79,6 +78,7 @@ spec:
|
|||
- name: {{ printf "%s" $envAll.Release.Name }}
|
||||
{{ tuple $envAll "compute_utility" | include "helm-toolkit.snippets.image" | indent 10 }}
|
||||
{{ tuple $envAll $envAll.Values.pod.resources.compute_utility | include "helm-toolkit.snippets.kubernetes_resources" | indent 10 }}
|
||||
{{ dict "envAll" $envAll "application" "compute" "container" "compute_utility" | include "helm-toolkit.snippets.kubernetes_container_security_context" | indent 10 }}
|
||||
command:
|
||||
- /tmp/bootstrap.sh
|
||||
readinessProbe:
|
||||
|
|
|
@ -41,6 +41,14 @@ labels:
|
|||
node_selector_value: primary
|
||||
|
||||
pod:
|
||||
security_context:
|
||||
compute:
|
||||
pod:
|
||||
runAsUser: 65534
|
||||
container:
|
||||
compute_utility:
|
||||
allowPrivilegeEscalation: true
|
||||
readOnlyRootFilesystem: false
|
||||
dns_policy: "ClusterFirstWithHostNet"
|
||||
replicas:
|
||||
utility: 1
|
||||
|
|
Loading…
Reference in New Issue