Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,9 @@ configure by setting environment variables when you create container.

* `REMOTE_DESKTOP`: nomachine (default) , kasmvnc, novnc.
* `VNC_THREADS`: RectThread num for vncserver, only used when `REMOTE_DESKTOP` = kasmvnc. default is 2, set 0 for auto.
* `HTTPS_CERT`: SSL pem certificate file path to use for https server(kasmvnc/nonvc)
* `HTTPS_CERT_KEY`: SSL pem key file path to use for https server(kasmvnc/nonvc)
* `HTTPS_CERT`: SSL pem certificate file path to use for https server(kasmvnc/nonvc).
* `HTTPS_CERT_KEY`: SSL pem key file path to use for https server(kasmvnc/nonvc).
* `DISABLE_HTTPS`: set 1 for http server mode, which is useful for reverse proxy.

#### Enable GPU hardware-accelerated rendering

Expand Down
6 changes: 5 additions & 1 deletion ubuntu-desktop/docker_config/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,11 @@ fi
# start dbus
/etc/init.d/dbus start
# start coder server
su $USER -c "code-server --cert $HTTPS_CERT --cert-key $HTTPS_CERT_KEY --bind-addr=0.0.0.0:5000 &"
if [ ! -z ${DISABLE_HTTPS+x} ]; then
su $USER -c "code-server --bind-addr=0.0.0.0:5000 &"
else
su $USER -c "code-server --cert $HTTPS_CERT --cert-key $HTTPS_CERT_KEY --bind-addr=0.0.0.0:5000 &"
fi
# start remote desktop
if [ "${REMOTE_DESKTOP}" = "nomachine" ]; then
echo "start nomachine"
Expand Down
2 changes: 1 addition & 1 deletion ubuntu-desktop/docker_config/install_code_server.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash
version=4.93.1
version=4.103.2
arch=$(dpkg --print-architecture)
codename=$(lsb_release --short --codename)
if [[ $codename == 'bionic' ]]; then
Expand Down
2 changes: 1 addition & 1 deletion ubuntu-desktop/docker_config/install_novnc.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/sh
NOVNC_VERSION=1.4.0
NOVNC_VERSION=1.6.0
# install turbovnc
wget -q -O- https://packagecloud.io/dcommander/turbovnc/gpgkey | gpg --dearmor >/etc/apt/trusted.gpg.d/TurboVNC.gpg
wget -O /etc/apt/sources.list.d/TurboVNC.list https://raw.githubusercontent.com/TurboVNC/repo/main/TurboVNC.list
Expand Down
6 changes: 5 additions & 1 deletion ubuntu-desktop/docker_config/start_kasmvnc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ if [ ! -f "/home/$USER/.vnc/passwd" ]; then
fi
rm -rf /tmp/.X1000-lock /tmp/.X11-unix/X1000
# start kasmvnc
su $USER -c "kasmvncserver :1000 -select-de xfce -interface 0.0.0.0 -websocketPort 4000 -cert $HTTPS_CERT -key $HTTPS_CERT_KEY -RectThreads $VNC_THREADS"
if [ ! -z ${DISABLE_HTTPS+x} ]; then
su $USER -c "kasmvncserver :1000 -select-de xfce -interface 0.0.0.0 -websocketPort 4000 -sslOnly 0 -RectThreads $VNC_THREADS"
else
su $USER -c "kasmvncserver :1000 -select-de xfce -interface 0.0.0.0 -websocketPort 4000 -cert $HTTPS_CERT -key $HTTPS_CERT_KEY -RectThreads $VNC_THREADS"
fi
su $USER -c "pulseaudio --start"
tail -f /home/$USER/.vnc/*.log
6 changes: 5 additions & 1 deletion ubuntu-desktop/docker_config/start_novnc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,9 @@ rm -rf /tmp/.X1000-lock /tmp/.X11-unix/X1000
# start TurboVNC
su $USER -c "/opt/TurboVNC/bin/vncserver :1000 -rfbport 5900"
# start NoVNC
su $USER -c "/opt/noVNC/utils/novnc_proxy --vnc localhost:5900 --ssl-only --cert $HTTPS_CERT --key $HTTPS_CERT_KEY --listen 4000 --heartbeat 10 &"
if [ ! -z ${DISABLE_HTTPS+x} ]; then
su $USER -c "/opt/noVNC/utils/novnc_proxy --vnc localhost:5900 --listen 4000 --heartbeat 10 &"
else
su $USER -c "/opt/noVNC/utils/novnc_proxy --vnc localhost:5900 --ssl-only --cert $HTTPS_CERT --key $HTTPS_CERT_KEY --listen 4000 --heartbeat 10 &"
fi
tail -f /home/$USER/.vnc/*.log