-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathDockerfile
More file actions
62 lines (48 loc) · 1.16 KB
/
Dockerfile
File metadata and controls
62 lines (48 loc) · 1.16 KB
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
59
60
61
62
FROM node:8
ENV CHROMEDRIVER_PORT 9515
ENV CHROMEDRIVER_WHITELISTED_IPS ""
ENV SCREEN_WIDTH 1920
ENV SCREEN_HEIGHT 1080
ENV SCREEN_DEPTH 24
ENV DISPLAY :99.0
ENV ELECTRON_CHROMEDRIVER_VERSION 1.7.1
USER root
RUN apt-get update -qqy
#=====
# VNC
#=====
RUN apt-get -qqy install \
x11vnc
#=======
# Fonts
#=======
RUN apt-get -qqy --no-install-recommends install \
fonts-ipafont-gothic \
xfonts-100dpi \
xfonts-75dpi \
xfonts-cyrillic \
xfonts-scalable
#=========
# fluxbox
# A fast, lightweight and responsive window manager
#=========
RUN apt-get -qqy install \
xvfb fluxbox
#=====
# Chromedriver dependencies
#=====
RUN apt-get -qqy install \
libnss3-dev libgconf-2-4 fuse libgtk2.0-0 libasound2
RUN rm -rf /var/lib/apt/lists/* /var/cache/apt/*
ADD entrypoint.sh /entrypoint.sh
RUN chmod 777 /entrypoint.sh
RUN npm install electron-chromedriver@$ELECTRON_CHROMEDRIVER_VERSION
#==============================
# Generating the VNC password as node
# So the service can be started with node
#==============================
RUN mkdir -p ~/.vnc \
&& x11vnc -storepasswd secret ~/.vnc/passwd
CMD ["/bin/bash", "/entrypoint.sh"]
EXPOSE 5900
EXPOSE 9515