Spaces:
Sleeping
Sleeping
FROM python:3.9 | |
WORKDIR /code | |
COPY ./requirements.txt /code/requirements.txt | |
# Install dependencies | |
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt | |
# Explicitly install Uvicorn | |
RUN pip install uvicorn | |
# Copy the rest of the application | |
COPY . . | |
# Command to run the application | |
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"] | |
# Set the environment variable for Matplotlib cache | |
ENV MPLCONFIGDIR=/tmp/matplotlib | |