binary1ne commited on
Commit
9b94fcd
·
verified ·
1 Parent(s): 3da3e4c

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +4 -21
Dockerfile CHANGED
@@ -4,44 +4,27 @@ FROM python:3.11-slim
4
  # Set the working directory inside the container.
5
  WORKDIR /app
6
 
7
- # Install system dependencies required for Git and Playwright.
8
- # We install a minimal set of libraries to keep the image small.
9
  RUN apt-get update \
10
  && apt-get install -y --no-install-recommends \
11
  git \
12
  libnss3 \
13
- libnspr4 \
14
  libdbus-1-3 \
15
  libatk1.0-0 \
16
  libatk-bridge2.0-0 \
17
- libcups2 \
18
  libdrm2 \
19
- libgdk-pixbuf2.0-0 \
20
- libglib2.0-0 \
21
- libgssapi-krb5-2 \
22
  libxcomposite1 \
23
- libxcursor1 \
24
- libxdamage1 \
25
  libxext6 \
26
  libxfixes3 \
27
- libxi6 \
28
  libxrandr2 \
29
- libxrender1 \
30
- libxkbcommon0 \
31
- libx11-xcb1 \
32
- libxshmfence1 \
33
  libgbm1 \
34
- libwayland-client0 \
35
- libwayland-egl1 \
36
- libwayland-cursor0 \
37
  libexpat1 \
38
  libfontconfig1 \
39
  libharfbuzz0b \
40
  libfreetype6 \
41
  libpng16-16 \
42
  libjpeg62-turbo \
43
- libwebp6 \
44
- libglib2.0-0 \
45
  && apt-get clean \
46
  && rm -rf /var/lib/apt/lists/*
47
 
@@ -54,11 +37,11 @@ WORKDIR /app/web-ui
54
  # Install Python dependencies using uv and install the Chromium browser with Playwright.
55
  RUN pip install uv \
56
  && uv pip install -r requirements.txt \
57
- && playwright install --with-deps chromium
58
 
59
  # Expose the default port for the web application.
60
  EXPOSE 7788
61
 
62
  # Command to run the application when the container starts.
63
  # We bind to 0.0.0.0 to make the web UI accessible from outside the container.
64
- CMD ["python", "webui.py", "--ip", "0.0.0.0", "--port", "7860"]
 
4
  # Set the working directory inside the container.
5
  WORKDIR /app
6
 
7
+ # Install system dependencies required for Git and a minimal set for Playwright.
8
+ # This list is based on the most common runtime dependencies for headless browsers.
9
  RUN apt-get update \
10
  && apt-get install -y --no-install-recommends \
11
  git \
12
  libnss3 \
 
13
  libdbus-1-3 \
14
  libatk1.0-0 \
15
  libatk-bridge2.0-0 \
 
16
  libdrm2 \
 
 
 
17
  libxcomposite1 \
 
 
18
  libxext6 \
19
  libxfixes3 \
 
20
  libxrandr2 \
 
 
 
 
21
  libgbm1 \
 
 
 
22
  libexpat1 \
23
  libfontconfig1 \
24
  libharfbuzz0b \
25
  libfreetype6 \
26
  libpng16-16 \
27
  libjpeg62-turbo \
 
 
28
  && apt-get clean \
29
  && rm -rf /var/lib/apt/lists/*
30
 
 
37
  # Install Python dependencies using uv and install the Chromium browser with Playwright.
38
  RUN pip install uv \
39
  && uv pip install -r requirements.txt \
40
+ && playwright install chromium
41
 
42
  # Expose the default port for the web application.
43
  EXPOSE 7788
44
 
45
  # Command to run the application when the container starts.
46
  # We bind to 0.0.0.0 to make the web UI accessible from outside the container.
47
+ CMD ["python", "webui.py", "--ip", "0.0.0.0", "--port", "7860"]