| FROM python:3.10-slim | |
| WORKDIR /code | |
| # Install the correct Debian compilers AND cmake so it builds fast | |
| RUN apt-get update && apt-get install -y build-essential gcc g++ cmake && rm -rf /var/lib/apt/lists/* | |
| COPY ./requirements.txt /code/requirements.txt | |
| # Notice I removed the extra-index-url so it builds cleanly for Debian! | |
| RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt | |
| COPY . . | |
| EXPOSE 7860 | |
| CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"] |