Spaces:
Sleeping
Sleeping
File size: 421 Bytes
34da398 123f615 34da398 123f615 34da398 123f615 34da398 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | FROM python:3.11-slim
RUN useradd -m -u 1000 user
ENV HOME=/home/user \
PATH=/home/user/.local/bin:$PATH \
PIP_NO_CACHE_DIR=1 \
PIP_DISABLE_PIP_VERSION_CHECK=1
WORKDIR $HOME/app
COPY --chown=user server/requirements.txt ./
RUN pip install --no-cache-dir -r requirements.txt
COPY --chown=user server/app ./app
USER user
EXPOSE 7860
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "7860"]
|