anacondamultiple-users

How to lock environments in a multi-user Conda install?


I'm managing a multiple user Conda installation. I want to provide a few basic environments, e.g. base, Tensorflow 1, Tensorflow 2, etc. that users can clone if they need more specific environments.

I've added users to the group per the install instructions here https://docs.anaconda.com/anaconda/install/linux/

Now, how can I "lock" these environments and prevent them from being modified? Currently, these are open issues for Anaconda ( https://github.com/conda/conda/issues/4943 and https://github.com/conda/conda/issues/4929 ) so I was wondering if anyone had a workaround here.


Solution

  • Try conda-pack. The workflow for your users will be slightly different, but you probably can write a little script that automates obtaining and unpacking tarballs creates by conda-pack (it even has a Python API).