Skip to content

Commit

Permalink
Use numeric uid:gid in Dockerfile to support Tanzu's PSP
Browse files Browse the repository at this point in the history
- Fixes issue
  "Error: container has runAsNonRoot and image has non-numeric user (nonroot), cannot verify user is non-root"
  • Loading branch information
lhotari authored Feb 14, 2024
1 parent da3c208 commit ead7a7b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@ RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 GO111MODULE=on go build -a -o manager
FROM gcr.io/distroless/static:nonroot
WORKDIR /
COPY --from=builder /workspace/manager .
USER nonroot:nonroot
USER 65532:65532

ENTRYPOINT ["/manager"]

0 comments on commit ead7a7b

Please sign in to comment.