[no-relnote] Remove unused code

Signed-off-by: Evan Lezar <elezar@nvidia.com>
This commit is contained in:
Evan Lezar 2024-09-11 11:40:34 +02:00
parent 5c3ffc2fba
commit 1afada7de5
No known key found for this signature in database
3 changed files with 0 additions and 29 deletions

View File

@ -20,15 +20,6 @@ const (
// HookConfig : options for the nvidia-container-runtime-hook. // HookConfig : options for the nvidia-container-runtime-hook.
type HookConfig config.Config type HookConfig config.Config
func getDefaultHookConfig() (HookConfig, error) {
defaultCfg, err := config.GetDefault()
if err != nil {
return HookConfig{}, err
}
return *(*HookConfig)(defaultCfg), nil
}
// loadConfig loads the required paths for the hook config. // loadConfig loads the required paths for the hook config.
func loadConfig() (*config.Config, error) { func loadConfig() (*config.Config, error) {
var configPaths []string var configPaths []string

View File

@ -24,13 +24,3 @@ type RuntimeHookConfig struct {
// SkipModeDetection disables the mode check for the runtime hook. // SkipModeDetection disables the mode check for the runtime hook.
SkipModeDetection bool `toml:"skip-mode-detection"` SkipModeDetection bool `toml:"skip-mode-detection"`
} }
// GetDefaultRuntimeHookConfig defines the default values for the config
func GetDefaultRuntimeHookConfig() (*RuntimeHookConfig, error) {
cfg, err := GetDefault()
if err != nil {
return nil, err
}
return &cfg.NVIDIAContainerRuntimeHookConfig, nil
}

View File

@ -45,13 +45,3 @@ type cdiModeConfig struct {
type csvModeConfig struct { type csvModeConfig struct {
MountSpecPath string `toml:"mount-spec-path"` MountSpecPath string `toml:"mount-spec-path"`
} }
// GetDefaultRuntimeConfig defines the default values for the config
func GetDefaultRuntimeConfig() (*RuntimeConfig, error) {
cfg, err := GetDefault()
if err != nil {
return nil, err
}
return &cfg.NVIDIAContainerRuntimeConfig, nil
}