Documentation of steps followed to build/install packages in stronghold environments. This documentation should aid creating and updating new environments.
- Basics
- Environments
- List environments:
conda info --envs
- List all packages in env with name
myenv
:conda list -n myenv
- Create environment with name
myenv
and specify python version:conda create -n myenv python=3.4
- Clone a previous environment:
conda create --name bcbi_v0.0.2 --clone bcbi_v0.0.1
- Activate environments:
source activate bcbi_v0.0.2
- Deactivate:
source deactivate
- Remove environment with name
myenv
:conda remove --name myenv --all
To avoid time outs, you may prefer to work in a screen session. Coomon commands are:
- start a new screen session with session name:
screen -S <name>
- list running sessions/screens:
screen -ls
- attach to a running session:
screen -x
- attach to session by name:
screen -r <name>
- detach:
C-a d
- detach and logout (quick exit):
C-a D D
- quit:
C-a :quit
Conda environments are created and set up on build server. However, they get distrubuted to the workstations as Pymodules via rsync. To make your environment available to the workstations follow these steps:
-
Register it as a PyModule and add related environment variables by editing
/opt/browncis/conda/conda
on build server -
Update the pymodules database:
moduledb insert -f /opt/browncis/conda/conda
on build server -
Now sync environments and pymodules database. This may take a while
ssh admin server
ssh software server
#(software server may time out before sync is complete)
screen -S screen_name
#sync environment and pymodule settings
sudo condasync
#may want to use anoth buffer ctrl-a c (ctrl-a ctrl-a)
sudo swsync
Confirm/load your module in stronghold workstation
- List:
module avail
- Load:
module load conda/env_name