Spaces:
Paused
Paused
Download Dockerfile from Speedofmastery/or: direct link, hf CLI and curl.
- Browser
- Download file 589 Bytes
-
https://huggingface.co/spaces/Speedofmastery/or/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/Speedofmastery/or/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/Speedofmastery/or/resolve/main/Dockerfile
589 Bytes
| # Simple production Docker with Python 3.10 | |
| FROM python:3.10 | |
| # Environment variables | |
| ENV PYTHONUNBUFFERED=1 \ | |
| GRADIO_SERVER_NAME=0.0.0.0 \ | |
| GRADIO_SERVER_PORT=7860 | |
| # Create user | |
| RUN useradd -m -u 1000 user | |
| USER user | |
| # Set paths | |
| ENV HOME=/home/user \ | |
| PATH=/home/user/.local/bin:$PATH | |
| WORKDIR $HOME/app | |
| # Copy and install requirements | |
| COPY --chown=user requirements.txt . | |
| RUN pip install --no-cache-dir --upgrade pip && \ | |
| pip install --no-cache-dir -r requirements.txt | |
| # Copy app | |
| COPY --chown=user app.py . | |
| # Expose port | |
| EXPOSE 7860 | |
| # Run app | |
| CMD ["python", "app.py"] | |