Merge pull request #57286 from vmware/controller-mgr-fix

Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Fixing vSphere Cloud Provider to use "vsphere-cloud-provider" to create ClientBuilder

**What this PR does / why we need it**:
vSphere cloud Provider is not using lower case naming while creating clientBuilder.
With this fix, ClientBuilder is created using lowercase naming.
With mixed upper-lower case name, controller manager is crashing.

**Which issue(s) this PR fixes** 
Fixes # https://github.com/kubernetes/kubernetes/issues/57279

**Special notes for your reviewer**:
None

**Release note**:
```release-note
This fixes controller manager crash in certain vSphere cloud provider environment.
```
pull/6/head
Kubernetes Submit Queue 2017-12-29 23:15:59 -08:00 committed by GitHub
commit da9a4d5da9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -217,7 +217,7 @@ func (vs *VSphere) Initialize(clientBuilder controller.ControllerClientBuilder)
// Only on controller node it is required to register listeners.
// Register callbacks for node updates
client := clientBuilder.ClientOrDie("vSphere-cloud-provider")
client := clientBuilder.ClientOrDie("vsphere-cloud-provider")
factory := informers.NewSharedInformerFactory(client, 5*time.Minute)
nodeInformer := factory.Core().V1().Nodes()
nodeInformer.Informer().AddEventHandler(cache.ResourceEventHandlerFuncs{