I want to build a Docker image that installs Ubuntu GNOME Desktop, tightvncserver and noVNC to remote access the container from a web browser.
In my Dockerfile, I install all the necessary GNOME packages:
RUN apt-get update && apt-get install -y \
ubuntu-desktop \
gnome-panel \
gnome-settings-daemon \
metacity \
nautilus \
gnome-terminal \
My xstartup file is:
#!/bin/sh
export XKL_XMODMAP_DISABLE=1
unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
/etc/X11/Xsession
vncconfig -iconic &
gnome-panel &
gnome-settings-daemon &
metacity &
nautilus &
gnome-terminal &
Unfortunately, when I login noVNC, I can only see a Desktop background and a single window; I have no menu bar, launchers etc.
I searched a long time around this topic but didn't find any clear answer how to make it work properly. Maybe I missed something out there. Any help appreciated, thanks!