Handle an empty scheduler ("")

This commit is contained in:
Lars Ekman 2022-12-23 13:23:02 +01:00
parent 90c03dcf9a
commit dc86bdc3aa

View File

@ -665,6 +665,10 @@ func CanUseIPVSProxier(ipvs utilipvs.Interface, ipsetver IPSetVersioner, schedul
return fmt.Errorf("ipset version: %s is less than min required version: %s", versionString, MinIPSetCheckVersion)
}
if scheduler == "" {
scheduler = defaultScheduler
}
// Check is any virtual servers (vs) are configured. If any, we assume
// that this is a kube-proxy re-start and skip the checks.
vservers, err := ipvs.GetVirtualServers()