diff --git a/pkg/descheduler/policyconfig.go b/pkg/descheduler/policyconfig.go index c9b91e8ee7..2005b38701 100644 --- a/pkg/descheduler/policyconfig.go +++ b/pkg/descheduler/policyconfig.go @@ -19,7 +19,7 @@ package descheduler import ( "context" "fmt" - "io/ioutil" + "os" "k8s.io/apimachinery/pkg/runtime" clientset "k8s.io/client-go/kubernetes" @@ -40,7 +40,7 @@ func LoadPolicyConfig(policyConfigFile string, client clientset.Interface, regis return nil, nil } - policy, err := ioutil.ReadFile(policyConfigFile) + policy, err := os.ReadFile(policyConfigFile) if err != nil { return nil, fmt.Errorf("failed to read policy config file %q: %+v", policyConfigFile, err) }