File size: 757 Bytes
dd5f0c2
a387aeb
4193fa1
a387aeb
4193fa1
 
a387aeb
 
 
 
 
 
b7a1653
4193fa1
 
a387aeb
 
 
dd5f0c2
a387aeb
 
b7a1653
 
 
 
4193fa1
a387aeb
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
FROM node:20

# Instal Python, FFmpeg, dan dependensi lainnya
RUN apt-get update && apt-get install -y \
    python3 \
    python3-pip \
    ffmpeg \
    imagemagick \
    webp \
    git && \
    apt-get clean

# Buat symbolic link Python
RUN ln -s /usr/bin/python3 /usr/bin/python

# Set direktori kerja
WORKDIR /app

# Clone repo
RUN git clone https://github.com/vakumah/DownloaderX.git .

# --- FIX BUG SYNTAX ERROR ---
# Menghapus teks "Invalid URL" yang nyasar di file facebook.js
RUN sed -i "s/mimetype: 'video\/mp4',Invalid URL/mimetype: 'video\/mp4',/g" src/features/facebook.js

# Instal dependensi bot
RUN npm install
RUN npm install express

# HF Spaces wajib jalan di port 7860
ENV PORT=7860
EXPOSE 7860

# Jalankan bot
CMD ["node", "index.js"]