Skip to content

Commit 7be619f

Browse files
J12934Ilyesbdlala
authored andcommitted
Remove duplicated user declaration / configuration
The image is already running as nonroot, specified via the image tag (`gcr.io/distroless/static:nonroot`) Specifing it here again using the username makes deploying it to kubernetes slightly more annoying as this failed the `runAsNonRoot` securityContext check as kubernetes can't verify that this is actually non-root as it's not configured via the uid. Signed-off-by: Jannik Hollenbach <[email protected]>
1 parent 616f9e4 commit 7be619f

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

Dockerfile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,5 @@ RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 GO111MODULE=on go build -a -o telemetr
2525
FROM gcr.io/distroless/static:nonroot
2626
WORKDIR /
2727
COPY --from=builder /workspace/telemetry .
28-
USER nonroot:nonroot
2928
ENV GIN_MODE release
3029
ENTRYPOINT ["/telemetry"]

0 commit comments

Comments
 (0)