Merge branch 'fix-nvidia-ctk-path' into 'main'

Fix issue with blank nvidia-ctk path

See merge request nvidia/container-toolkit/container-toolkit!297
This commit is contained in:
Evan Lezar 2023-02-16 13:58:43 +00:00 committed by Evan Lezar
parent 2081750bea
commit bc37b97c73

View File

@ -47,6 +47,9 @@ func FindNvidiaCTK(logger *logrus.Logger, nvidiaCTKPath string) string {
return nvidiaCTKPath return nvidiaCTKPath
} }
if nvidiaCTKPath == "" {
nvidiaCTKPath = nvidiaCTKExecutable
}
logger.Debugf("Locating NVIDIA Container Toolkit CLI as %v", nvidiaCTKPath) logger.Debugf("Locating NVIDIA Container Toolkit CLI as %v", nvidiaCTKPath)
lookup := lookup.NewExecutableLocator(logger, "") lookup := lookup.NewExecutableLocator(logger, "")
hookPath := nvidiaCTKDefaultFilePath hookPath := nvidiaCTKDefaultFilePath