- Install docker
- Install socat (see install.sh)
- Install XQuartz from https://www.xquartz.org
-
Obtain your VirtualBox host IP Address. This is NOT the VirtualBox VM IP Address.
$ VBOXNET=$(ifconfig vboxnet0 | grep inet | awk '{ print $2}')
-
Run XQuartz. (You may close the terminal)
-
Forward your display (
socat
MAY NOTfork()
properly)$ socat TCP-LISTEN:6000,bind=${VBOXNET},reuseaddr,fork UNIX-CLIENT:\"$DISPLAY\"
-
Run your Linux GUI docker container (in a new window if
socat
does notfork()
)$ docker run -it --rm -e DISPLAY=${VBOXNET}:0 chrisdaish/firefox