-
Notifications
You must be signed in to change notification settings - Fork 4
/
Dockerfile-xrdp.maui
132 lines (123 loc) · 4.44 KB
/
Dockerfile-xrdp.maui
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
# FROM ubuntu:rolling
FROM ubuntu:impish-20220128
RUN apt update && DEBIAN_FRONTEND=noninteractive apt install -y kubuntu-desktop
RUN rm -f /run/reboot-required*
RUN useradd -m testuser -p $(openssl passwd 1234)
RUN usermod -aG sudo testuser
RUN apt install -y xrdp
RUN adduser xrdp ssl-cert
##########################################################
WORKDIR /root
RUN apt install -y wget git cmake extra-cmake-modules build-essential gettext
RUN apt install -y \
libkf5coreaddons-dev \
libkf5i18n-dev \
libkf5kio-dev \
qtbase5-dev \
qtdeclarative5-dev \
qtquickcontrols2-5-dev
RUN apt install -y \
libkf5i18n-dev \
libkf5kio-dev \
libkf5notifications-dev \
libkf5solid-dev \
libkf5syntaxhighlighting-dev \
libqt5svg5-dev \
libqt5x11extras5-dev \
libxcb-icccm4-dev \
libxcb-shape0-dev \
qml-module-qtgraphicaleffects \
qml-module-qtquick-controls2 \
qml-module-qtquick-shapes \
qtbase5-dev \
qtdeclarative5-dev \
qtquickcontrols2-5-dev
RUN apt install -y \
libkf5config-dev \
libkf5coreaddons-dev \
libkf5i18n-dev \
libkf5idletime-dev \
libkf5kio-dev \
libkf5notifications-dev \
libkf5service-dev \
libqt5svg5-dev \
libqt5waylandcompositor5-dev \
qtbase5-dev \
qtdeclarative5-dev \
qtquickcontrols2-5-dev
# Runtime Dependencies
RUN apt install -y \
bluedevil \
libkf5bluezqt6 \
libkf5kirigami2-5 \
plasma-framework \
plasma-nm \
plasma-pa \
qml-module-org-kde-bluezqt \
qml-module-org-kde-kirigami2 \
qml-module-qt-labs-calendar \
qml-module-qt-labs-platform \
qml-module-qtwayland-compositor
# 1. Build MauiKit in Ubuntu
RUN git clone --depth 1 --branch master https://invent.kde.org/maui/mauikit.git
RUN mkdir -p mauikit/build
RUN cd mauikit/build && cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DENABLE_BSYMBOLICFUNCTIONS=OFF \
-DQUICK_COMPILER=ON \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_SYSCONFDIR=/etc \
-DCMAKE_INSTALL_LOCALSTATEDIR=/var \
-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON \
-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON \
-DCMAKE_INSTALL_RUNSTATEDIR=/run "-GUnix Makefiles" \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_INSTALL_LIBDIR=/usr/lib/x86_64-linux-gnu ..
RUN cd mauikit/build && make
RUN cd mauikit/build && make install
# 2. Build MauiKit FileBrowsing Ubuntu
RUN git clone --depth 1 --branch master https://invent.kde.org/maui/mauikit-filebrowsing.git
RUN mkdir -p mauikit-filebrowsing/build
RUN cd mauikit-filebrowsing/build && cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DENABLE_BSYMBOLICFUNCTIONS=OFF \
-DQUICK_COMPILER=ON \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_SYSCONFDIR=/etc \
-DCMAKE_INSTALL_LOCALSTATEDIR=/var \
-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON \
-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON \
-DCMAKE_INSTALL_RUNSTATEDIR=/run "-GUnix Makefiles" \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_PREFIX_PATH=/usr/lib/x86_64-linux-gnu/cmake/MauiKit ..
RUN cd mauikit-filebrowsing/build && make
RUN cd mauikit-filebrowsing/build && make install
# 3. Build Maui Shell Ubuntu
RUN git clone --depth 1 --branch master https://github.com/Nitrux/maui-shell.git
RUN mkdir -p maui-shell/build
RUN cd maui-shell/build && cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DENABLE_BSYMBOLICFUNCTIONS=OFF \
-DQUICK_COMPILER=ON \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_SYSCONFDIR=/etc \
-DCMAKE_INSTALL_LOCALSTATEDIR=/var \
-DCMAKE_EXPORT_NO_PACKAGE_REGISTRY=ON \
-DCMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY=ON \
-DCMAKE_INSTALL_RUNSTATEDIR=/run "-GUnix Makefiles" \
-DCMAKE_VERBOSE_MAKEFILE=ON \
-DCMAKE_PREFIX_PATH="/usr/lib/x86_64-linux-gnu/cmake/MauiKit;/usr/lib/x86_64-linux-gnu/cmake/MauiKitFileBrowsing" ..
RUN cd maui-shell/build && make
RUN cd maui-shell/build && make install
##########################################################
RUN sed -i '3 a echo "\
startcask-x11" > ~/.Xsession' /etc/xrdp/startwm.sh
RUN sed -i '3 a echo "\
export QT_AUTO_SCREEN_SCALE_FACTOR=0\\n\
export QT_XCB_GL_INTEGRATION=xcb_egl\\n\
export XDG_SESSION_TYPE=x11\\n\
export XDG_RUNTIME_DIR=/tmp/runtime-xdg-$USER\\n\
export XDG_CONFIG_DIRS=/etc/xdg/xdg-cask-x11:/etc/xdg\\n\
" > ~/.xsessionrc' /etc/xrdp/startwm.sh
EXPOSE 3389
CMD service dbus start ; /usr/lib/systemd/systemd-logind & service xrdp start ; bash