prometheus-node-exporter: Fix security context
This PS fixes the use of the security context macros for the node-exporter chart. Change-Id: I7009a5675096036ac9f214d70c853830b7132264
This commit is contained in:
parent
274697f9cf
commit
bc9bbe4e34
@ -55,8 +55,7 @@ spec:
|
||||
{{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" | indent 8 }}
|
||||
configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }}
|
||||
spec:
|
||||
securityContext:
|
||||
readOnlyRootFilesystem: true
|
||||
{{ dict "envAll" $envAll "application" "metrics" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }}
|
||||
serviceAccountName: {{ $serviceAccountName }}
|
||||
{{ if .Values.pod.tolerations.node_exporter.enabled }}
|
||||
{{ tuple $envAll "node_exporter" | include "helm-toolkit.snippets.kubernetes_tolerations" | indent 6 }}
|
||||
@ -72,6 +71,7 @@ spec:
|
||||
- name: node-exporter
|
||||
{{ tuple $envAll "node_exporter" | include "helm-toolkit.snippets.image" | indent 10 }}
|
||||
{{ tuple $envAll $envAll.Values.pod.resources.node_exporter | include "helm-toolkit.snippets.kubernetes_resources" | indent 10 }}
|
||||
{{ dict "envAll" $envAll "application" "metrics" "container" "node_exporter" | include "helm-toolkit.snippets.kubernetes_container_security_context" | indent 10 }}
|
||||
command:
|
||||
- /tmp/node-exporter.sh
|
||||
ports:
|
||||
|
@ -37,6 +37,14 @@ labels:
|
||||
node_selector_value: enabled
|
||||
|
||||
pod:
|
||||
security_context:
|
||||
metrics:
|
||||
pod:
|
||||
runAsUser: 65534
|
||||
container:
|
||||
node_exporter:
|
||||
readOnlyRootFilesystem: true
|
||||
allowPrivilegeEscalation: false
|
||||
affinity:
|
||||
anti:
|
||||
type:
|
||||
|
Loading…
Reference in New Issue
Block a user