ChatUI / Dockerfile
Asukaa02's picture
ChatUI Studio v2.0 — FastAPI + Transformers, multi-model / multi-task / agent
d2bc8de
Raw History Blame Contribute Delete
681 Bytes
# ChatUI Studio — Docker image for HuggingFace Spaces
# Pure FastAPI + transformers app, listens on port 7860.
FROM python:3.12-slim
# System deps for sentencepiece / torch
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
git \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
# Install Python deps first (cache layer)
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy app code
COPY app.py ./
COPY static ./static
COPY README.md ./
# HuggingFace Spaces runs everything on port 7860
ENV HF_HOME=/tmp/hf_cache
ENV TRANSFORMERS_CACHE=/tmp/hf_cache
ENV PORT=7860
EXPOSE 7860
CMD ["python", "app.py"]