CheckInAPI / Dockerfile
ethnmcl's picture
Update Dockerfile
6182c59 verified
raw
history blame
699 Bytes
# Dockerfile
FROM python:3.11-slim
# Optional: speed up HF downloads & cache in container
ENV HF_HOME=/data/huggingface \
HF_HUB_ENABLE_HF_TRANSFER=1 \
PIP_NO_CACHE_DIR=1 \
PYTHONUNBUFFERED=1
# -------- MODEL CONFIG --------
# Build-time overrideable default
ARG MODEL_ID=ethnmcl/checkin-lora-gpt2
# Runtime ENV (can still be overridden by deploy env)
ENV MODEL_ID=${MODEL_ID}
# Optional: if private model, pass HF_TOKEN at runtime only (not here)
# ENV HF_TOKEN=...
WORKDIR /app
COPY requirements.txt /app/requirements.txt
RUN pip install --upgrade pip && pip install -r requirements.txt
COPY . /app
EXPOSE 7860
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]