maylinejix commited on
Commit
3f85f8b
·
verified ·
1 Parent(s): fda1c0e

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +34 -7
Dockerfile CHANGED
@@ -1,16 +1,43 @@
1
- FROM node:18-slim
2
 
3
- RUN apt-get update && apt-get install -y git && rm -rf /var/lib/apt/lists/*
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4
 
5
  WORKDIR /app
6
 
7
- # Perbaiki: gunakan COPY . . atau COPY . /app
8
- COPY . .
 
 
9
 
10
- RUN npm install
11
 
12
- RUN npx playwright install --with-deps chromium || true
13
 
14
  EXPOSE 7860
15
 
16
- CMD ["node", "index.js"]
 
1
+ FROM python:3.11-slim
2
 
3
+ RUN apt-get update && apt-get install -y \
4
+ git \
5
+ wget \
6
+ curl \
7
+ gnupg \
8
+ ca-certificates \
9
+ fonts-liberation \
10
+ libasound2 \
11
+ libatk-bridge2.0-0 \
12
+ libatk1.0-0 \
13
+ libatspi2.0-0 \
14
+ libcups2 \
15
+ libdbus-1-3 \
16
+ libdrm2 \
17
+ libgbm1 \
18
+ libgtk-3-0 \
19
+ libnspr4 \
20
+ libnss3 \
21
+ libwayland-client0 \
22
+ libxcomposite1 \
23
+ libxdamage1 \
24
+ libxfixes3 \
25
+ libxkbcommon0 \
26
+ libxrandr2 \
27
+ xdg-utils \
28
+ && rm -rf /var/lib/apt/lists/*
29
 
30
  WORKDIR /app
31
 
32
+ COPY requirements.txt .
33
+ RUN pip install --no-cache-dir -r requirements.txt
34
+
35
+ RUN python -m camoufox fetch
36
 
37
+ COPY . .
38
 
39
+ RUN mkdir -p public
40
 
41
  EXPOSE 7860
42
 
43
+ CMD ["python", "app.py"]