mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-25 04:33:26 +00:00
Clean up kube-controller-manager.
These are based on recommendation from [staticcheck](http://staticcheck.io/).
This commit is contained in:
parent
8f5a62af48
commit
9327c4bbbc
@ -48,8 +48,8 @@ func createCloudProvider(cloudProvider string, externalCloudVolumePlugin string,
|
|||||||
return nil, loopMode, fmt.Errorf("cloud provider could not be initialized: %v", err)
|
return nil, loopMode, fmt.Errorf("cloud provider could not be initialized: %v", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
if cloud != nil && cloud.HasClusterID() == false {
|
if cloud != nil && !cloud.HasClusterID() {
|
||||||
if allowUntaggedCloud == true {
|
if allowUntaggedCloud {
|
||||||
klog.Warning("detected a cluster without a ClusterID. A ClusterID will be required in the future. Please tag your cluster to avoid any future issues")
|
klog.Warning("detected a cluster without a ClusterID. A ClusterID will be required in the future. Please tag your cluster to avoid any future issues")
|
||||||
} else {
|
} else {
|
||||||
return nil, loopMode, fmt.Errorf("no ClusterID Found. A ClusterID is required for the cloud provider to function properly. This check can be bypassed by setting the allow-untagged-cloud option")
|
return nil, loopMode, fmt.Errorf("no ClusterID Found. A ClusterID is required for the cloud provider to function properly. This check can be bypassed by setting the allow-untagged-cloud option")
|
||||||
|
Loading…
Reference in New Issue
Block a user