TransWikia.com

Nvidia Docker VNC with OpenGl and virtual display

Super User Asked by johni07 on January 6, 2021

We are currently setting up a docker environment for our students in which OpenGL applications should run.

To make access very easy I use my previous docker image where xvfb was used to create a virtual frame buffer and noVNC to make VNC accessible within the browser. The entrypoint Looks like this:


echo "starting xvfb"

Xvfb :99 -ac -screen 0 "$XVFB_WHD" -nolisten tcp &

Xvfb_pid="$!"



echo "start the x11 vnc server"

x11vnc -display :99 --loop -noxrecord &



echo "starting noVNC"

/novnc/noVNC/utils/launch.sh --vnc localhost:5900 &



In combination with a build mesa driver, this works quite well. However, now we need a more powerfull OpenGL driver than the llvmpipe.

For the base image I’m now using nvidia/cudagl:10.2-devel-ubuntu18.04, however as xvfb is used, the application will only use the llvmpipe again.

We know, that there is the option to share the X context between host and container with:


docker run … -v /tmp/.X11-unix:/tmp/.X11-unix -e XAUTHORITY … 

But then the application is also visible on the host. Is there an alternative to ‘xvfb’ where the NVIDIA GL driver is used? Or can we share the X context without showing the application on the host?

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP