-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
55 lines (46 loc) · 1.16 KB
/
Dockerfile
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
FROM python:3.11-slim
# Install necessary dependencies
RUN apt-get update && \
apt-get install -y --no-install-recommends \
fonts-liberation \
libasound2 \
libatk-bridge2.0-0 \
libatk1.0-0 \
libatspi2.0-0 \
libcups2 \
libdbus-1-3 \
libdrm2 \
libgbm1 \
libgtk-3-0 \
libnspr4 \
libnss3 \
libwayland-client0 \
libxcomposite1 \
libxdamage1 \
libxfixes3 \
libxkbcommon0 \
libxrandr2 \
xdg-utils \
libu2f-udev \
libvulkan1 \
curl \
libcurl4 \
wget && \
rm -rf /var/lib/apt/lists/*
# Copy the Chrome installer from the root of the project to the image
COPY google-chrome-stable_current_amd64.deb /tmp/
# Install Google Chrome from the local path
RUN apt-get install -y /tmp/google-chrome-stable_current_amd64.deb && \
rm /tmp/google-chrome-stable_current_amd64.deb
# Display Chrome version
RUN echo "Chrome: " && google-chrome --version
# Set working directory
WORKDIR /app
# Copy the application code
COPY . /app
# Install Python dependencies
RUN pip3 install --no-cache-dir -r requirements.txt
# Expose port
EXPOSE 5000
# Set the default command
CMD ["python", "run.py"]