49 lines
1.5 KiB
Docker
49 lines
1.5 KiB
Docker
# syntax=docker/dockerfile:1
|
|
FROM ubuntu:jammy as base
|
|
|
|
ENV DEBIAN_FRONTEND=noninteractive
|
|
ENV PASSWORD=vnc4me
|
|
RUN apt-get update
|
|
|
|
# Build tools
|
|
RUN apt-get install -y git build-essential libtool autotools-dev automake cmake nasm
|
|
RUN apt-get install -y x11vnc libx11-dev libxext-dev xvfb
|
|
RUN apt-get install -y libpam0g-dev
|
|
RUN apt-get install -y python3
|
|
|
|
FROM base as sources
|
|
ADD https://github.com/libjpeg-turbo/libjpeg-turbo.git /tmp/turbojpeg
|
|
ADD https://github.com/TurboVNC/turbovnc.git /tmp/turbovnc
|
|
|
|
FROM sources as build
|
|
WORKDIR "/tmp/turbojpeg/build"
|
|
RUN cmake -G"Unix Makefiles" ..
|
|
RUN make -j4 && make install
|
|
|
|
WORKDIR "/tmp/turbovnc/build"
|
|
RUN cmake -G"Unix Makefiles" -DTVNC_BUILDVIEWER:BOOL=false ..
|
|
RUN make -j4 && make install
|
|
|
|
RUN apt-get install -y icewm
|
|
RUN apt-get install -y x11-apps
|
|
|
|
# develop only
|
|
RUN apt-get install -y net-tools socat
|
|
|
|
ENV PATH=$PATH:/opt/TurboVNC/bin
|
|
RUN mkdir ~/.vnc/
|
|
RUN echo $PASSWORD | vncpasswd -f > ~/.vnc/passwd
|
|
RUN chmod 0600 ~/.vnc/passwd
|
|
|
|
EXPOSE 5900
|
|
|
|
COPY app/*.sh /app/
|
|
CMD ["/app/app.sh"]
|
|
|
|
# https://dunedlin.wordpress.com/2020/10/24/a-minimal-x11-install/
|
|
# https://askubuntu.com/questions/1313445/how-do-i-install-vnc-on-a-headless-ubuntu-20-10
|
|
# https://github.com/mviereck/x11docker/wiki/How-to-access-X-over-TCP-IP-network
|
|
# https://jaydenm.com/blog/docker-x11-desktop/
|
|
# https://github.com/karinepires/docker-secure-vncserver/blob/master/Dockerfile
|
|
# https://github.com/theonemule/docker-opengl-turbovnc/blob/master/dockerfile
|