Skip to content
Dockerfile 1.13 KiB
Newer Older
FROM base
MAINTAINER Stefano Alberto Russo <stefano.russo@inaf.it>

# Switch to root
USER root


#------------------------
#------------------------

# Install xvfb that triggers minimal install of X base packages and xterm as sample application,
# plus Python3 which is required for Kasm VNC
RUN apt-get install xvfb xterm net-tools python3 libjpeg8 libgomp1 -y
# Kasm VNC (modded by gtaffoni to use a socket named by an env var)
COPY files/kasmvnc.ubuntu_focal.tar.gz /tmp
RUN sudo tar xz --strip 1 -C / -f /tmp/kasmvnc.ubuntu_focal.tar.gz && rm /tmp/kasmvnc.ubuntu_focal.tar.gz

# X environment setup/startup
RUN mkdir -p /metauser_home_vanilla/.vnc
COPY files/xstartup /metauser_home_vanilla/.vnc
RUN chmod 755 /metauser_home_vanilla/.vnc/xstartup

# KASM VNC startup script
COPY files/run_kasm.sh /usr/local/bin/run_kasm.sh
RUN chmod 755 /usr/local/bin/run_kasm.sh


#------------------------
# Post-intall
#------------------------

# Fix home permissions
RUN chmod 777 /home

# Set entrypoint command
ENV DEFAULT_ENTRYPOINT_COMMAND="/usr/local/bin/run_kasm.sh"

# Set user
USER metauser

# Set container name
Stefano Alberto Russo's avatar
Stefano Alberto Russo committed
ENV CONTAINER_NAME='x11web'