Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

run image as non-root user & add securitycontext values#138

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
ericpaulsen merged 2 commits intomainfromimage-user
Oct 3, 2025
Merged
Show file tree
Hide file tree
Changes fromall 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
4 changes: 4 additions & 0 deletionshelm/templates/service.yaml
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -98,6 +98,10 @@ spec:
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.podSecurityContext }}
podSecurityContext:
{{- toYaml . | nindent 8 }}
{{- end }}
containers:
-name:coder-logstream-kube
image:"{{ .Values.image.repo }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
Expand Down
12 changes: 10 additions & 2 deletionshelm/values.yaml
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -92,12 +92,20 @@ labels: {}

# securityContext -- Container-level security context
# See: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/
securityContext: {}
# allowPrivilegeEscalation: false
securityContext:
runAsNonRoot: true
runAsUser: 65532
runAsGroup: 65532
allowPrivilegeEscalation: false
# capabilities:
# drop:
# - ALL
# readOnlyRootFilesystem: true
# runAsNonRoot: true
# seccompProfile:
# type: RuntimeDefault

podSecurityContext: {}
# Optional, only if your cluster requires group ownership for mounted volumes:
# podSecurityContext:
# fsGroup: 65532
3 changes: 2 additions & 1 deletionscripts/Dockerfile
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
FROM --platform=$BUILDPLATFORM scratch AS base
ARG TARGETARCH
COPY ./coder-logstream-kube-${TARGETARCH} /coder-logstream-kube
COPY --chmod=0555 ./coder-logstream-kube-${TARGETARCH} /coder-logstream-kube
USER 65532:65532
ENTRYPOINT ["/coder-logstream-kube"]
Loading

[8]ページ先頭

©2009-2025 Movatter.jp