Remove Set from engine config API

Signed-off-by: Evan Lezar <elezar@nvidia.com>
This commit is contained in:
Evan Lezar
2025-01-27 15:38:55 +01:00
parent 1bc9548a2f
commit ce7cea3a0d
4 changed files with 7 additions and 23 deletions

View File

@@ -105,7 +105,7 @@ func (c Config) DefaultRuntime() string {
// EnableCDI sets features.cdi to true in the docker config.
func (c *Config) EnableCDI() {
c.Set("features", map[string]bool{"cdi": true})
(*c)["features"] = map[string]bool{"cdi": true}
}
// RemoveRuntime removes a runtime from the docker config
@@ -137,11 +137,6 @@ func (c *Config) RemoveRuntime(name string) error {
return nil
}
// Set sets the specified docker option
func (c *Config) Set(key string, value interface{}) {
(*c)[key] = value
}
// Save writes the config to the specified path
func (c Config) Save(path string) (int64, error) {
output, err := json.MarshalIndent(c, "", " ")