# Use an official Python runtime as a base image FROM python:3.9-slim # Set the working directory in the container to /app WORKDIR /app # Copy the current directory contents into the container at /app ADD . /app # Install any needed packages specified in requirements.txt RUN apt-get update && \ apt-get install -y aria2 curl gcc python3-dev && \ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && \ . $HOME/.cargo/env && \ pip install --upgrade pip && \ pip install --no-cache-dir -r requirements.txt # Run download_model.sh RUN bash download_model.sh # Make port 80 available to the world outside this container EXPOSE 80 # Run app.py when the container launches CMD ["python", "app.py"]