forked from sfoxdev/docker-ubuntu-rdp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
79 lines (67 loc) · 2.78 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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
FROM ubuntu:16.04
MAINTAINER SFoxDev <[email protected]>
ENV PASSWORD="" \
DEBIAN_FRONTEND="noninteractive" \
TERM="xterm" \
LC_ALL="C.UTF-8" \
LANG="en_US.UTF-8" \
LANGUAGE="en_US.UTF-8"
ADD https://dl.google.com/linux/linux_signing_key.pub /tmp/
RUN sed -i "s/# deb-src/deb-src/g" /etc/apt/sources.list ; \
apt-key add /tmp/linux_signing_key.pub ; \
echo 'deb http://dl.google.com/linux/chrome/deb/ stable main' >> /etc/apt/sources.list ; \
echo 'deb http://dl.google.com/linux/chrome-remote-desktop/deb/ stable main' >> /etc/apt/sources.list ; \
apt-get -y update ; \
apt-get -yy upgrade
ENV BUILD_DEPS="git autoconf pkg-config libssl-dev libpam0g-dev \
libx11-dev libxfixes-dev libxrandr-dev nasm xsltproc flex \
bison libxml2-dev dpkg-dev libcap-dev"
RUN apt-get -yy install \
sudo apt-utils software-properties-common vim wget ca-certificates \
xfce4 xfce4-terminal xfce4-screenshooter xfce4-taskmanager \
xfce4-clipman-plugin xfce4-cpugraph-plugin xfce4-netload-plugin \
xfce4-xkb-plugin xauth supervisor uuid-runtime pulseaudio locales \
pepperflashplugin-nonfree openssh-server \
google-chrome-stable x11vnc mc \
$BUILD_DEPS ; \
cd /tmp ; \
apt-get source pulseaudio ; \
apt-get build-dep -yy pulseaudio ; \
cd /tmp/pulseaudio-8.0 ; \
dpkg-buildpackage -rfakeroot -uc -b ; \
cd /tmp ; \
git clone --branch v0.9.4 --recursive https://github.com/neutrinolabs/xrdp.git ; \
cd /tmp/xrdp ; \
./bootstrap ; ./configure ; make ; make install ; \
cd /tmp/xrdp/sesman/chansrv/pulse ; \
sed -i "s/\/tmp\/pulseaudio\-10\.0/\/tmp\/pulseaudio\-8\.0/g" Makefile ; \
make ; \
cp *.so /usr/lib/pulse-8.0/modules/ ; \
cd /tmp ; \
git clone --branch v0.2.4 --recursive https://github.com/neutrinolabs/xorgxrdp.git ; \
apt-get -yy install xserver-xorg-dev ; \
cd /tmp/xorgxrdp ; \
./bootstrap ; ./configure ; make ; make install ; \
cd / ; \
apt-get -yy remove xscreensaver $BULD_DEPS ; \
apt-get -yy autoremove ; \
apt-get -yy clean ; \
rm -rf /var/cache/* /var/log/apt/* /var/lib/apt/lists/* /tmp/*
ADD data/ /
RUN mkdir /var/run/dbus ; \
cp /etc/X11/xrdp/xorg.conf /etc/X11 ; \
#sed -i "s/console/anybody/g" /etc/X11/Xwrapper.config ; \
sed -i "s/xrdp\/xorg/xorg/g" /etc/xrdp/sesman.ini ; \
locale-gen en_US.UTF-8 ; \
echo "xfce4-session" > /etc/skel/.Xclients ; \
cp -r /etc/ssh /ssh_orig ; \
rm -rf /etc/ssh/* ; \
rm -rf /etc/xrdp/rsakeys.ini /etc/xrdp/*.pem ; \
addgroup chrome ; \
useradd -m -s /bin/bash -g chrome chrome ; \
echo "chrome:chrome" | /usr/sbin/chpasswd ; \
echo "chrome ALL=(ALL) ALL" >> /etc/sudoers
#VOLUME ["/etc/ssh","/home"]
EXPOSE 3389 22 9001
ENTRYPOINT ["/usr/bin/docker-entrypoint.sh"]
CMD ["supervisord"]