mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-03 01:06:27 +00:00
Fix panic in vSphere when deploying on a single ESX node.
Use ComputeResource instead of ClusterComputeResource when initializing the vSphere Cloud Provider
This commit is contained in:
parent
bb0bc660cf
commit
26db528da3
@ -252,7 +252,7 @@ func readInstance(cfg *VSphereConfig) (string, string, error) {
|
|||||||
var rp mo.ResourcePool
|
var rp mo.ResourcePool
|
||||||
err = s.Properties(ctx, *vm.ResourcePool, []string{"parent"}, &rp)
|
err = s.Properties(ctx, *vm.ResourcePool, []string{"parent"}, &rp)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
var ccr mo.ClusterComputeResource
|
var ccr mo.ComputeResource
|
||||||
err = s.Properties(ctx, *rp.Parent, []string{"name"}, &ccr)
|
err = s.Properties(ctx, *rp.Parent, []string{"name"}, &ccr)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
cluster = ccr.Name
|
cluster = ccr.Name
|
||||||
|
Loading…
Reference in New Issue
Block a user