-
Notifications
You must be signed in to change notification settings - Fork 146
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
Dockerfile for production #482
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.
suggest creating 2 files for the moment; e.g. Dockerfile.prod
and Dockerfile.dev
and build the appropriate file. entrypoint file is a great idea.
It would be nice to generate a |
I'd like to keep the main Improving the I'll added generating the |
# Run app and all commands as user 'app'. This avoids changing permissions | ||
# for files in mounted volume. | ||
RUN adduser --gecos GECOS --disabled-password --shell /bin/bash app | ||
USER app |
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.
Wait a minute, does removing this mean that Foodsoft now runs as root? (Hope this is not a newbie Docker question.)
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.
It's very uncommon to create a special user just for running the main entry point. Since it's a Docker container there are no "real root" rights in the container anyway and having an additional user does not offer a lot of additional security to the underlying system.
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.
Makes sense. Thanks for explaining!
Thanks! And looking good. Besides the run-as-question, ready to merge, I'd say. Did you manage to re-setup the docker hub build? |
Updating the |
Great 👍 I know @dan-nl is working on a separate development and production docker setup, let's rework the rest with that. |
One thing I didn't see yet: how about asset precompilation? |
No description provided.