Skip to content

Commit

Permalink
fix: modify Dockerfile to run container as non root user
Browse files Browse the repository at this point in the history
  • Loading branch information
tomaszbarwicki committed Jun 12, 2024
1 parent 0029ed2 commit aed8250
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ WORKDIR /app
COPY ./web /app/web
COPY --from=builder --chown=nonroot:nonroot /app/dashboard /app/dashboard

RUN adduser -u 1000 --disabled-password --gecos "" --no-create-home nonroot
USER nonroot

ENTRYPOINT ["/app/dashboard"]

CMD ["-in-cluster=true"]
CMD ["-in-cluster=true"]

0 comments on commit aed8250

Please sign in to comment.