Merge "Maas: Add pod/container security context"

This commit is contained in:
Zuul 2019-05-20 16:12:51 +00:00 committed by Gerrit Code Review
commit 290bbf1adc
2 changed files with 10 additions and 0 deletions

View File

@ -35,6 +35,7 @@ spec:
labels:
{{ tuple $envAll "maas" "ingress-errors" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 8 }}
spec:
{{ dict "envAll" $envAll "application" "ingress_errors" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
serviceAccountName: {{ $serviceAccountName }}
nodeSelector:
{{ .Values.labels.rack.node_selector_key }}: {{ .Values.labels.rack.node_selector_value }}
@ -44,6 +45,7 @@ spec:
image: {{ .Values.images.tags.error_pages }}
imagePullPolicy: {{ .Values.images.pull_policy }}
{{ tuple $envAll $envAll.Values.pod.resources.maas_ingress_errors | include "helm-toolkit.snippets.kubernetes_resources" | indent 10 }}
{{ dict "envAll" $envAll "application" "ingress_errors" "container" "maas_ingress_errors" | include "helm-toolkit.snippets.kubernetes_container_security_context" | indent 10 }}
command:
- /tmp/maas-ingress-errors.sh
- start

View File

@ -240,6 +240,14 @@ pod:
maas-rack: localhost/docker-default
maas-region:
maas-region: localhost/docker-default
security_context:
ingress_errors:
pod:
runAsUser: 99
container:
maas_ingress_errors:
runAsUser: 0
readOnlyRootFilesystem: true
affinity:
anti:
type: