# Dockerfile — FINAL FROM python:3.11-slim # Install system dependencies (NO FFMPEG since you want it optional!) RUN apt-get update && \ apt-get install -y --no-install-recommends \ build-essential \ libsqlite3-dev \ curl \ wget \ && rm -rf /var/lib/apt/lists/* # Set working dir WORKDIR /app # Copy all source code COPY . /app/ # Create necessary dirs RUN mkdir -p ./downloads ./logs ./data && \ chmod -R 777 ./downloads ./logs ./data # Install python requirements RUN pip install --upgrade pip RUN pip install -r requirements.txt # Expose web port for FastAPI health EXPOSE 7860 # Final CMD — run main.py (bot + web) CMD ["python", "main.py"]