I have a virtual machine on Azure where after ssh'ing I can run Conda and python alright:
conda activate py36
python some_script.py
To run these commands from my machine through SSH, I need to give the full path to Conda:
ssh ${USER}@${IP} "/data/anaconda/envs/py35/bin/conda activate py36; python some_script.py"
but I get this error:
CommandNotFoundError: Your shell has not been properly configured to use 'conda activate'.
To initialize your shell, run
$ conda init <SHELL_NAME>
Currently supported shells are:
- bash
- fish
- tcsh
- xonsh
- zsh
- powershell
See 'conda init --help' for more information and options.
IMPORTANT: You may need to close and restart your shell after running 'conda init'.
Yet, the shell running is bash:
$ sshb ${USER}@${IP} echo $SHELL
/bin/bash
How can I activate a conda environment remotely through SSH?