Bumblebee-Project / Bumblebee

Bumblebee daemon and client rewritten in C
http://www.bumblebee-project.org/
GNU General Public License v3.0
1.29k stars 144 forks source link

Bumblebee using docker does not display application window #1061

Closed tallysmartins closed 3 years ago

tallysmartins commented 3 years ago

Hi guys. I have a laptop with optimus config. My bumblebee works just fine on my host. My issue came when I tryed to containerize my application. docker + nvidia opengl. Must be nvidia because I will use cuda integration with it.

I have it almost working, docker executes GL apps using mesa drivers. Apps displays oks.

The problem is when I try to use the DISPLAY=:8 . It executes the application i.e.g glxgears -info the application executes, shows Nvidia driver info, but the window does not show up.

Running synchronized to the vertical refresh.  The framerate should be
approximately the same as the monitor refresh rate.
GL_RENDERER   = GeForce 940MX/PCIe/SSE2
GL_VERSION    = 4.6.0 NVIDIA 440.100
GL_VENDOR     = NVIDIA Corporation

I think primus is not capturing the GL calls from docker. I thought that I needed to redirect it to the bumblebee socket in /var/run/bumblebee.socket but idk if this make sense.

tallysmartins commented 3 years ago

I installed primus inside the container and was able to use it using optirun glxgears -info. Probably I was missing some step that bumblebee does before calling primus.

Closing this issue.