Fixed noVNC

This commit is contained in:
butomo1989 2017-04-06 10:29:27 +02:00
parent a60c418b21
commit 0a605cf226
2 changed files with 17 additions and 10 deletions

View file

@ -10,8 +10,6 @@ WORKDIR /root
#================== #==================
# General Packages # General Packages
#------------------ #------------------
# git
# Clone git repository
# wget # wget
# Network downloader # Network downloader
# unzip # unzip
@ -52,7 +50,6 @@ WORKDIR /root
# bridge-utils # bridge-utils
#================== #==================
RUN apt-get update && apt-get install -y --no-install-recommends \ RUN apt-get update && apt-get install -y --no-install-recommends \
git \
wget \ wget \
unzip \ unzip \
curl \ curl \
@ -72,11 +69,22 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
bridge-utils \ bridge-utils \
&& rm -rf /var/lib/apt/lists/* && rm -rf /var/lib/apt/lists/*
#====================== #=======
# Clone noVNC projects # noVNC
#====================== # Use same commit id that docker-selenium uses
RUN git clone https://github.com/kanaka/noVNC.git \ # https://github.com/elgalu/docker-selenium/blob/236b861177bd2917d864e52291114b1f5e4540d7/Dockerfile#L412-L413
&& cd noVNC/utils && git clone https://github.com/kanaka/websockify websockify #=======
ENV NOVNC_SHA="b403cb92fb8de82d04f305b4f14fa978003890d7" \
WEBSOCKIFY_SHA="558a6439f14b0d85a31145541745e25c255d576b"
RUN wget -O noVNC.zip "https://github.com/kanaka/noVNC/archive/${NOVNC_SHA}.zip" \
&& unzip -x noVNC.zip \
&& rm noVNC.zip \
&& mv noVNC-${NOVNC_SHA} noVNC \
&& wget -O websockify.zip "https://github.com/kanaka/websockify/archive/${WEBSOCKIFY_SHA}.zip" \
&& unzip -x websockify.zip \
&& mv websockify-${WEBSOCKIFY_SHA} ./noVNC/utils/websockify \
&& rm websockify.zip \
&& ln noVNC/vnc_auto.html noVNC/index.html
#===================== #=====================
# Install Android SDK # Install Android SDK
@ -133,7 +141,6 @@ ENV DISPLAY=:0 \
TARGET_PORT=6080 \ TARGET_PORT=6080 \
TIMEOUT=1 \ TIMEOUT=1 \
LOG_PATH=/var/log/supervisor LOG_PATH=/var/log/supervisor
RUN ln -s noVNC/vnc_auto.html noVNC/index.html
#=============== #===============
# Expose Ports # Expose Ports

View file

@ -14,7 +14,7 @@ stdout_logfile=%(ENV_LOG_PATH)s/openbox.stdout.log
stderr_logfile=%(ENV_LOG_PATH)s/openbox.stderr.log stderr_logfile=%(ENV_LOG_PATH)s/openbox.stderr.log
[program:x11vnc] [program:x11vnc]
command=/usr/bin/x11vnc -display %(ENV_DISPLAY)s -nopw -ncache 10 -forever command=/usr/bin/x11vnc -display %(ENV_DISPLAY)s -nopw -forever -shared
stdout_logfile=%(ENV_LOG_PATH)s/x11vnc.stdout.log stdout_logfile=%(ENV_LOG_PATH)s/x11vnc.stdout.log
stderr_logfile=%(ENV_LOG_PATH)s/x11vnc.stderr.log stderr_logfile=%(ENV_LOG_PATH)s/x11vnc.stderr.log