-
Notifications
You must be signed in to change notification settings - Fork 176
run_code as a user instead of root #94
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_code as a user instead of root #94
Conversation
This won't be probably backwards compatible right?
Can I specify if I want run something as root?
This comment was marked as outdated.
This comment was marked as outdated.
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.
I think we just need to be able to pass user. Otherwise, someone might need to run something as root, leading to the same issue.
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.
why are you doing it as last thing? If you would set the user as a first thing you probably don't need change the ownership
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.
the problem here is: "user" does not exist in python image
and we cannot add user before we have "sudo" dependency installed
so this is why it's the last
I created a new template, code-interpreter-v1beta1
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.
one thing: this is a breaking change, should I put a script in /root/.jupyter/start-up.sh that just calls the actual start-up.sh with sudo -u user?
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.
There's a path inconsistency between the Dockerfile and startup script. In the Dockerfile, the matplotlibrc file is copied to $HOME/.config/matplotlib/matplotlibrc (without a dot prefix), but in start-up.sh it's referenced as $HOME/.config/matplotlib/.matplotlibrc (with a dot prefix).
To resolve this, either:
- Update this line to include the dot prefix:
COPY matplotlibrc $HOME/.config/matplotlib/.matplotlibrc, or - Update the path in
start-up.shto remove the dot prefix:MATPLOTLIBRC=$HOME/.config/matplotlib/matplotlibrc
This will ensure the file is correctly located where the startup script expects to find it.
Spotted by Diamond
Is this helpful? React 👍 or 👎 to let us know.
Uh oh!
There was an error while loading. Please reload this page.
Sample code