-
Notifications
You must be signed in to change notification settings - Fork 8
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Run as non-root users #121
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 LGTM.
Didn't test, but there is an e2e test that uses these docker images so if that passes we are good.
Dockerfile
Outdated
@@ -34,20 +34,40 @@ RUN pnpm run --recursive build | |||
|
|||
# Create a separate stage for pusher package. We create a temporary stage for deployment and then copy the result into | |||
# the final stage. Only the production dependencies and package implementation is part of this last stage. | |||
ENV name="deployed-pusher" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we use the ENV (and the similar one below) somewhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah, no, I'll remove it. I tried to use this ENV originally to reduce duplication/single source of truth but Dockerfiles seemingly can't work this way.
Closes #117
As per the linked issue this PR adds largely a copy of the process used in the airseeker-v2 Dockerfile to make the "app" run as a non-privileged user.
I tried to use variable substitution to reduce the duplication but Dockerfiles are seemingly very limited in that area.