I am trying to spin up a Python web application on an AWS EC2 instance running Ubuntu 22. I am using mamba
as a package manager and have the packages written into an environment.yml
file. Running mamba env create --file=environment.yml
works perfectly for creating a virtual environment (and running the app) on my local machine. However, on my new EC2 instance, the process stops after printing Looking for: ['python=3.11', 'langchain', 'openai', 'tiktoken', 'pandas', 'streamlit', 'pip']
and then waiting about 5 seconds. I don't know if the issue is coming from something related to Ubuntu, EC2, or mamba and I am unsure how to troubleshoot this.
The entirety of commands run on this instance so far:
# download and install mamba
curl -L -O "https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-$(uname)-$(uname -m).sh"
bash Mambaforge-$(uname)-$(uname -m).sh
git clone https://github.com/username/repo
mamba env create --file=environment.yml
The contents of environment.yml
name: environment-name
channels:
- conda-forge
- nodefaults
dependencies:
- python=3.11
- langchain
- openai
- tiktoken
- pandas
- streamlit
- pip
- pip:
- streamlit-authenticator
Very belated answer to my own question, in case anyone else has the same issue: the problem was limited RAM. Simply upsize the instance, build the environment, and then downsize the instance, as needed.