-
Notifications
You must be signed in to change notification settings - Fork 14
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
New conda environments in ~/.conda/ by default #348
Conversation
c347b9c
to
08b5292
Compare
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!
Just a reminder, we need to be careful to add more configurations to home folder. As mentioned in #347 (comment), when starting the image by singleuser.sh by spawner in production deployment, the mounted home volume will be wiped. |
I am not sure how #347 (comment) is related to this PR. For sure, the bug needs to be fixed. Unrelated to that, keeping the conda environment in the home folder seems the right choice. |
My concern is even in this PR the P.S I'll give this change a test by using the new image in THEOS deployment. |
Sorry, I was wrong about this, I didn't look carefully at the change. This PR didn't make any modifications to the home folder. |
@unkcpz indeed.Here I only modified the global conda configuration, which is itself stored I believe in |
In the current image, when a user creates a new conda environment with
conda create --name new-env
, it will be created in/opt/conda/envs
, but that's no good since it will not be persisted between container invocation.In the QeApp, this is solved by specifying the full path to the environment like this:
conda create -p ~/.conda/envs/quantum-espresso
https://github.com/aiidalab/aiidalab-qe/blob/d6b6d046d42b186be60bbd34ca8d001a3fc4060a/aiidalab_qe/setup_codes.py#L44
But the disadvantage is that to activate this environment, one needs to provide the full path as well, which is clumsy.
In this PR I modify the conda config so that the new environments are created in
~/.conda/envs/
by default.This change actually makes the behavior consistent with the old docker stack image, so it should make migration easier for AiiDAlab app developers.
Closes #352