# Use a Python 3.10 Slim image as the base FROM python:3.10-slim # Set the working directory in the container WORKDIR /code # Copy the requirements file to the container COPY ./requirements.txt /code/requirements.txt # Upgrade pip to the latest version and install the dependencies RUN pip install --no-cache-dir --upgrade pip && \ pip install --no-cache-dir -r /code/requirements.txt # Copy the rest of the project files into the container COPY . . # Set the default command to run your application CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]