Spaces:
Runtime error
Runtime error
Vinoth
feat: switch to webhook mode for Hugging Face Spaces (16GB RAM), port 7860, auto-webhook setup
ea36919 Download Dockerfile from Vinoth-46/YT-Automation: direct link, hf CLI and curl.
- Browser
- Download file 884 Bytes
-
https://huggingface.co/spaces/Vinoth-46/YT-Automation/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/Vinoth-46/YT-Automation/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/Vinoth-46/YT-Automation/resolve/main/Dockerfile
884 Bytes
| # Use an official Python runtime as a parent image | |
| FROM python:3.12-slim | |
| # Install system dependencies (FFmpeg is crucial for video automation) | |
| RUN apt-get update && apt-get install -y \ | |
| ffmpeg \ | |
| libsm6 \ | |
| libxext6 \ | |
| gcc \ | |
| python3-dev \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Set the working directory in the container | |
| WORKDIR /app | |
| # Copy the requirements file into the container | |
| COPY requirements.txt . | |
| # Install any needed packages specified in requirements.txt | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Copy the rest of the application code | |
| COPY . . | |
| # Create necessary directories | |
| RUN mkdir -p assets outputs temp credentials | |
| # Expose port 7860 (required by Hugging Face Spaces) | |
| EXPOSE 7860 | |
| # Set PYTHONPATH to ensure 'bot' and other modules are found | |
| ENV PYTHONPATH=/app | |
| # Command to run the bot as a module | |
| CMD ["python", "-m", "bot.main"] | |