how to init-activate conda and run a python file in AWS ECS container?

Viewed 103

Firstly, I need to be able to write multiple commands for this task which I couldn't find how. When I try to activate to output is:

2021-05-10 22:00:33CommandNotFoundError: Your shell has not been properly configured to use 'conda activate'.
2021-05-10 22:00:33To initialize your shell, run
2021-05-10 22:00:33$ conda init <SHELL_NAME>
2021-05-10 22:00:33Currently supported shells are:
2021-05-10 22:00:33- bash
2021-05-10 22:00:33- fish
2021-05-10 22:00:33- tcsh
2021-05-10 22:00:33- xonsh
2021-05-10 22:00:33- zsh
2021-05-10 22:00:33- powershell
2021-05-10 22:00:33See 'conda init --help' for more information and options.
2021-05-10 22:00:33IMPORTANT: You may need to close and restart your shell after running 'conda init'.

When I try to init output is:

2021-05-10 22:03:24no change /opt/conda/condabin/conda
2021-05-10 22:03:24no change /opt/conda/bin/conda
2021-05-10 22:03:24no change /opt/conda/bin/conda-env
2021-05-10 22:03:24no change /opt/conda/bin/activate
2021-05-10 22:03:24no change /opt/conda/bin/deactivate
2021-05-10 22:03:24no change /opt/conda/etc/profile.d/conda.sh
2021-05-10 22:03:24no change /opt/conda/etc/fish/conf.d/conda.fish
2021-05-10 22:03:24no change /opt/conda/shell/condabin/Conda.psm1
2021-05-10 22:03:24no change /opt/conda/shell/condabin/conda-hook.ps1
2021-05-10 22:03:24no change /opt/conda/lib/python3.8/site-packages/xontrib/conda.xsh
2021-05-10 22:03:24no change /opt/conda/etc/profile.d/conda.csh
2021-05-10 22:03:24modified /root/.bashrc
2021-05-10 22:03:24==> For changes to take effect, close and re-open your current shell. <==

Therefore I need to run multiple commands to init conda then restart shell and activate and environment and run a python script. How can I run multiple commands in aws-ecs-container-prompt?

0 Answers
Related