-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Add entries to passwd/group if running as user not in passwd file. #559
Add entries to passwd/group if running as user not in passwd file. #559
Conversation
Excellent, thank you! I think we can still look at whether it makes sense to consolidate much of this into an entrypoint as you had with the new logic in #553, but I think it's good to have it all together either way. |
@GrahamDumpleton I'm testing with OpenShift 3.7, and getting permission errors:
In my local testing, I create a new image by setting the GID environment var to 0 and running the "fix-permissions" script on the folders that are failing... that image works in OpenShift. |
When deploying to OpenShift, you must set the supplemental groups in the security context of the deployment config to include UID 100 in the list of groups. For example templates which do the required setup for deployment see: |
Also look through: That has examples/templates for deploying JupyterHub, the notebook viewer, as well as S2I based build images for building notebook images from scratch in OpenShift that do not require the supplemental groups to be set. |
There are various warnings output from
which indicates what the issue is in this case. Maybe that and all the other messages should be output with a 'WARNING' prefix to make them more obvious that a configuration change is likely required in way image is being run. |
A warning prefix sounds reasonable. Or would it be better to have the image startup fail outright? |
For some of them, it doesn't necessarily mean you can't do anything, would just affect corner cases. Enabling Jupyter Lab interface is first case seen where the notebook wouldn't even start up. |
I wouldn't call enabling Jupyter Lab a corner case... I failed to mention in my post above that I changed the startup CMD to ["start.sh", "jupyter", "lab"] for that OpenShift deployment. |
I am not saying Jupyter Lab is the corner case, I have other things in mind, like a small number of Python packages that don't handle missing entries in passwd/group file properly. Different situation, although with changes have made to You didn't need to override start command. See: |
Alternate PR to address #552.
See also discussion against prior PR at #553.
This PR does everything in
start.sh
with only other change being inDockerfile
to make passwd and group files writable by root group.