mirror of
https://github.com/NVIDIA/nvidia-container-toolkit
synced 2025-06-26 18:18:24 +00:00
Add management mode to CDI spec generation API
These changes add support for generating a management spec to the nvcdi API. A management spec consists of a single CDI device (`all`) which includes all expected NVIDIA device nodes, driver libraries, binaries, and IPC sockets. Signed-off-by: Evan Lezar <elezar@nvidia.com>
This commit is contained in:
@@ -73,6 +73,11 @@ func New(opts ...Option) Interface {
|
||||
|
||||
var lib Interface
|
||||
switch l.resolveMode() {
|
||||
case ModeManagement:
|
||||
if l.vendor == "" {
|
||||
l.vendor = "management.nvidia.com"
|
||||
}
|
||||
lib = (*managementlib)(l)
|
||||
case ModeNvml:
|
||||
if l.nvmllib == nil {
|
||||
l.nvmllib = nvml.New()
|
||||
|
||||
Reference in New Issue
Block a user