1
Fork 0
mirror of https://github.com/Steffo99/patched-porobot.git synced 2024-12-22 09:34:21 +00:00

Run container as a non-privileged user

Uses the `USER` instruction.

See https://stackoverflow.com/questions/68155641/should-i-run-things-inside-a-docker-container-as-non-root-for-safety .
This commit is contained in:
Steffo 2023-04-05 12:24:10 +02:00 committed by GitHub
parent 12e6f8ad32
commit 29e3853867
Signed by: github
GPG key ID: 4AEE18F83AFDEB23

View file

@ -69,6 +69,7 @@ COPY --from=builder \
/usr/src/patched_porobot/target/*/release/patched_porobot_matrix \ /usr/src/patched_porobot/target/*/release/patched_porobot_matrix \
/usr/bin/ /usr/bin/
USER ${UID}:${GID}
ENTRYPOINT [] ENTRYPOINT []
CMD [] CMD []