Nawah-Router-Demo / Dockerfile
oddadmix's picture
Redesign: interactive Docker/FastAPI demo on the routing-head model
532cbb3 verified
Raw
History Blame Contribute Delete
406 Bytes
FROM python:3.12-slim
ENV PYTHONUNBUFFERED=1 HF_HOME=/tmp/hf TRANSFORMERS_VERBOSITY=error OMP_NUM_THREADS=4
WORKDIR /app
RUN pip install --no-cache-dir \
torch --index-url https://download.pytorch.org/whl/cpu \
&& pip install --no-cache-dir "transformers>=5.15,<6" fastapi "uvicorn[standard]" huggingface_hub
COPY . /app
EXPOSE 7860
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]