nvidia container runtime in LXC container?

I'd like to enable hardware-accelerated video transcoding via an Nvidia GPU card for an instance of Plex Media Server running inside PVE's flavor of LXC container.

Has anyone been successful in enabling Nvidia GPU pass-through on Proxmox using nvidia-container-runtime? (LXC or KVM, doesn't matter to me).

I'm not that familiar with LXC, even less so with the layers above that Proxmox VE adds. Nvidia has had Docker support for a while, and more recently restructured nvidia-container-runtime so it can be used with LXC, too.

The LXC support isn't as well documented as the Docker side, and with the extra Proxmox VE extensions, creating a 'naked' LXC container by following their recipe means Proxmox seems to be blissfully unaware of its existence. So no better than just installing Docker and using the pre-baked Docker images that Nivida has on Docker Hub. I'm reluctant to add another container type not managed by PVE if I can avoid it.

In fact, Nvidia's LXC instructions convert their docker image to a 'native' LXC container via the LXC OCI template.

I'm sure I'll eventually figure out how to align the moving parts to get it working, but it's proving a bit frustrating at the moment. Just wondering if someone has cracked this nut already.

Pointers very much appreciated. In a perfect world, there would be a template I could just use to create an Nvidia-enabled LXC container through the PVE web UI ;)

- Paul



The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!