Spaces:
Sleeping
Sleeping
Download Dockerfile from aseelflihan/syncmaster2: direct link, hf CLI and curl.
- Browser
- Download file 970 Bytes
-
https://huggingface.co/spaces/aseelflihan/syncmaster2/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/aseelflihan/syncmaster2/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/aseelflihan/syncmaster2/resolve/main/Dockerfile
970 Bytes
| # | |
| # -- Dockerfile for Streamlit app -- | |
| # | |
| # Base image | |
| FROM python:3.9-slim | |
| # Set working directory | |
| WORKDIR /app | |
| # Install system dependencies (including ffmpeg) | |
| RUN apt-get update && apt-get install -y \ | |
| build-essential \ | |
| ffmpeg \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Copy requirements file | |
| COPY requirements.txt ./requirements.txt | |
| # Install Python dependencies | |
| RUN pip install --no-cache-dir --upgrade pip | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Copy the entire app | |
| COPY . . | |
| # Create .streamlit directory and set permissions | |
| RUN mkdir -p /app/.streamlit && \ | |
| chmod -R 755 /app/.streamlit | |
| # Set environment variable for Streamlit config | |
| ENV STREAMLIT_CONFIG_DIR=/app/.streamlit | |
| # Expose the port that Streamlit runs on | |
| EXPOSE 8501 | |
| # Add a health check | |
| HEALTHCHECK CMD curl --fail http://localhost:8501/_stcore/health | |
| # Command to run the app | |
| ENTRYPOINT ["streamlit", "run", "app.py", "--server.port=8501", "--server.address=0.0.0.0"] | |