Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update security context for standalone chart #109

Merged
merged 2 commits into from
Jan 27, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 8 additions & 5 deletions charts/memgraph/templates/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,13 +62,11 @@ spec:
chown -R memgraph:memgraph {{ .Values.persistentVolumeClaim.userMountPath }};
{{- end }}
securityContext:
privileged: true
readOnlyRootFilesystem: false
readOnlyRootFilesystem: true
runAsUser: 0
capabilities:
drop: ["all"]
drop: ["ALL"]
add: ["CHOWN"]
runAsUser: 0
runAsNonRoot: false
{{- if .Values.sysctlInitContainer.enabled }}
- name: init-sysctl
image: busybox
Expand Down Expand Up @@ -128,6 +126,11 @@ spec:
containerPort: {{ .Values.service.websocketPortMonitoring }}
- name: http
containerPort: {{ .Values.service.httpPortMonitoring }}
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop: [ "ALL" ]
# Run by 'memgraph' user as specified in the Dockerfile
livenessProbe:
exec:
command:
Expand Down
Loading