Expose Incus Nvidia Config Options in TrueNAS UI

Problem/Justification
I was trying to replicate my jailmaker config using an lxc instance created through the truenas ui. When atempting to install the nvidia drivers so my jellyfin could use it for transcoding i get a kernel miss-match error because the drvier version truenas uses (550.142) is newer then the package version (535.183.1).
After some searching through the incus documentation and their forum i discovered, that you can passthrough the nvidia host configuration to the instance.
See Instance options - Incus documentation

Since it’s already possible to passthrough a gpu to an incus instance it would be nice to have either the options exposed via gui checkbox or include the passthrough options in the already existing gpu passthrough checkbox (and add a tooltip that the checkbox will also passthrough the nvidia host configurations) .
Without it you can’t use your gpu in an incus instance.

If i’ve understood it correctly the recommendation is to passthrough

nvidia.driver.capabilities
nvidia.require.cuda
nvidia.require.driver

but install the runtime locally in the instance itself.

Impact
This would propably reduce the support requests for people who want to run gpu based workloads inside lxc instances.

1 Like

It would be nice if this were twofold:

  1. Allow ticking a box for the Nvidia configs when an Nvidia card is present.
  2. Have a custom setting similar to environment variables to enter multiple custom config options.

This should allow custom config options not configured by IX.

I’ll put up another request for custom cloud-init config import and editing that config once it has been imported.

nvidia AND intel would be nice