Add directories where to look for conda environments - vicgalle/wiki-example GitHub Wiki

The conda configuration file, ~/.condarc, is an optional runtime configuration file that allows advanced users to configure various aspects of conda, such as which channels it searches for packages, proxy settings and environment directories.

The ~/.condarc file is not included by default, but it is automatically created in your home directory the first time you run the command:

$ conda config

Then you add a path to the field envs_dirs:

$ conda config --add envs_dirs <path-to-envs-dir>

Alternative form

In order to add more directories where to look for environments, you add the following line to the ~/.condarc file (note that by default there are curly brackets {} that must be removed)

envs_dirs:
  - <path>

Example:

envs_dirs:
  - /home/data/ucadatalab_group/envs

Practical use

This is useful to have shared environments among the users in a remote machine. Instead of everyone installing the same environment for a project in its local directories, everyone uses the shared one.

Sources

https://conda.io/projects/conda/en/latest/user-guide/configuration/use-condarc.html#specify-environment-directories-envs-dirs

https://conda.io/projects/conda/en/latest/user-guide/configuration/sample-condarc.html

https://conda.io/projects/conda/en/latest/user-guide/configuration/use-condarc.html#expansion-of-environment-variables

⚠️ **GitHub.com Fallback** ⚠️