Ahmed Mostafa commited on
Commit
e7a10ab
·
1 Parent(s): 729a17c

config the docker file

Browse files
Files changed (1) hide show
  1. Dockerfile +7 -2
Dockerfile CHANGED
@@ -5,10 +5,12 @@ FROM python:3.10-slim
5
  ENV PYTHONDONTWRITEBYTECODE 1
6
  ENV PYTHONUNBUFFERED 1
7
 
8
- # Install system dependencies
9
  RUN apt-get update && apt-get install -y \
10
  ffmpeg \
11
  git \
 
 
12
  && rm -rf /var/lib/apt/lists/*
13
 
14
  # Set work directory
@@ -19,6 +21,9 @@ WORKDIR /app
19
  COPY requirements.txt .
20
  RUN pip install --no-cache-dir -r requirements.txt
21
 
 
 
 
22
  # Copy the rest of the application
23
  COPY . .
24
 
@@ -26,4 +31,4 @@ COPY . .
26
  EXPOSE 7860
27
 
28
  # Run the application using the robust entry point
29
- CMD ["python", "run.py", "server"]
 
5
  ENV PYTHONDONTWRITEBYTECODE 1
6
  ENV PYTHONUNBUFFERED 1
7
 
8
+ # Install system dependencies including Node.js for yt-dlp JS challenge solver
9
  RUN apt-get update && apt-get install -y \
10
  ffmpeg \
11
  git \
12
+ nodejs \
13
+ npm \
14
  && rm -rf /var/lib/apt/lists/*
15
 
16
  # Set work directory
 
21
  COPY requirements.txt .
22
  RUN pip install --no-cache-dir -r requirements.txt
23
 
24
+ # Force latest yt-dlp so JS challenge definitions are up to date
25
+ RUN pip install -U yt-dlp
26
+
27
  # Copy the rest of the application
28
  COPY . .
29
 
 
31
  EXPOSE 7860
32
 
33
  # Run the application using the robust entry point
34
+ CMD ["python", "run.py", "server"]