workwise-backend-gpu / Dockerfile.bak2
VcRlAgent's picture
To HF
92f791e
raw
history blame contribute delete
656 Bytes
RUN useradd -m -u 1000 user
WORKDIR /home/user/app
# Minimal system dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
git \
&& rm -rf /var/lib/apt/lists/*
# Copy requirements first
COPY --chown=1000:1000 requirements.txt .
# Install Python packages efficiently
RUN pip install --no-cache-dir -U pip && \
pip install --no-cache-dir \
fastapi==0.104.1 \
uvicorn[standard]==0.24.0 \
sentence-transformers \
faiss-cpu \
torch \
transformers \
pydantic
# Copy app
COPY --chown=1000:1000 . .
USER user
EXPOSE 7860
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "7860"]