Technical-Docs-QA / Dockerfile
mokarami's picture
Upload folder using huggingface_hub
529d699 verified
Raw
History Blame Contribute Delete
715 Bytes
FROM python:3.11-slim
ENV PYTHONDONTWRITEBYTECODE=1 \
PYTHONUNBUFFERED=1 \
PIP_NO_CACHE_DIR=1 \
TOKENIZERS_PARALLELISM=false \
OMP_NUM_THREADS=1 \
MKL_NUM_THREADS=1 \
HOME=/home/user \
PATH=/home/user/.local/bin:$PATH \
HOST=0.0.0.0 \
PORT=7860
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
git \
libgomp1 \
&& rm -rf /var/lib/apt/lists/*
RUN useradd -m -u 1000 user
USER user
WORKDIR $HOME/app
COPY --chown=user requirements.txt requirements.txt
RUN python -m pip install --upgrade pip && \
python -m pip install -r requirements.txt
COPY --chown=user . .
EXPOSE 7860
CMD ["python", "scripts/run_real_qa_api.py"]