-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathDockerfile
More file actions
58 lines (47 loc) · 1008 Bytes
/
Dockerfile
File metadata and controls
58 lines (47 loc) · 1008 Bytes
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
56
57
58
FROM python:3.10-alpine
EXPOSE 5900
COPY ./requirements.txt /tmp/requirements.txt
COPY ./app /app
COPY ./scripts /scripts
# Install temporary dependencies
RUN apk update && apk upgrade && \
apk add --no-cache --virtual .build-deps \
alpine-sdk \
curl \
wget \
unzip \
gnupg
# Install dependencies
RUN apk add --no-cache \
xvfb \
x11vnc \
fluxbox \
xterm \
libffi-dev \
openssl-dev \
zlib-dev \
bzip2-dev \
readline-dev \
sqlite-dev \
git \
nss \
freetype \
freetype-dev \
harfbuzz \
ca-certificates \
ttf-freefont \
chromium \
chromium-chromedriver
# Install x11vnc
RUN mkdir ~/.vnc
RUN x11vnc -storepasswd 1234 ~/.vnc/passwd
# Install Python dependencies
RUN pip install --no-cache-dir -r /tmp/requirements.txt && \
rm /tmp/requirements.txt
WORKDIR /app
RUN chmod -R +x /scripts
ENV PATH="/scripts:$PATH"
ENV DISPLAY=:0
# Delete temporary dependencies
RUN apk del .build-deps
CMD startup.sh