-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathDockerfile
40 lines (24 loc) · 1.1 KB
/
Dockerfile
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
FROM ubuntu:18.04
ENV DEBIAN_FRONTEND=noninteractive
# Helpers
RUN apt-get update && apt-get install -y vim xterm pulseaudio cups
RUN apt-get -y dist-upgrade
RUN apt-get install -y mate-desktop-environment-core mate-desktop-environment mate-indicator-applet ubuntu-mate-themes ubuntu-mate-wallpapers chromium-browser firefox nano sudo
RUN apt-get install -y wget
RUN wget https://download.nomachine.com/download/6.5/Linux/nomachine_6.5.6_9_amd64.deb -O /nomachine.deb
RUN dpkg -i /nomachine.deb
RUN apt-get clean
RUN apt-get autoclean
RUN echo 'pref("browser.tabs.remote.autostart", false);' >> /usr/lib/firefox/browser/defaults/preferences/vendor-firefox.js
RUN rm -rf /var/lib/apt/lists/*
RUN groupadd -r nomachine -g 433 && \
useradd -u 431 -r -g nomachine -d /home/nomachine -s /bin/bash -c "NoMachine" nomachine && \
mkdir /home/nomachine && \
chown -R nomachine:nomachine /home/nomachine && \
echo 'nomachine:nomachine' | chpasswd
RUN echo "nomachine ALL=(ALL) ALL" >> /etc/sudoers
EXPOSE 4000
VOLUME [ "/home/nomachine" ]
ADD nxserver.sh /
RUN chmod +x /nxserver.sh
ENTRYPOINT ["/nxserver.sh"]