Spaces:
Sleeping
Sleeping
File size: 610 Bytes
8ab058b 64b4096 8ab058b 64b4096 8ab058b 64b4096 8ab058b 64b4096 8ab058b 64b4096 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
FROM python:3.10 as build
RUN useradd -m -u 1000 user
USER user
# Set home to the user's home directory
ENV HOME=/home/user \
PATH=/home/user/.local/bin:$PATH
# Set the working directory to the user's home directory
WORKDIR $HOME/app
COPY --chown=user requirements-cpu.txt requirements-gui.txt ./
RUN pip install --no-cache-dir -r requirements-cpu.txt -r requirements-gui.txt --extra-index-url https://download.pytorch.org/whl/cpu
FROM build as final
COPY --chown=user . .
# download weights
RUN python download_files.py --overwrite
CMD [ "python", "./predict-gui.py", "--server_name", "0.0.0.0" ]
|