Skip to content

Commit

Permalink
use external CCM for GCE (#347)
Browse files Browse the repository at this point in the history
  • Loading branch information
xrstf authored Jan 12, 2024
1 parent b178a7f commit d9581af
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions pkg/cloudprovider/cloudprovider.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,15 +60,11 @@ func GetCloudConfig(pconfig providerconfigtypes.Config, kubeletVersion string) (

func KubeletCloudProviderConfig(cloudProvider providerconfigtypes.CloudProvider, external bool) (inTreeCCM bool, outOfTree bool, err error) {
switch osmv1alpha1.CloudProvider(cloudProvider) {
case osmv1alpha1.CloudProviderAWS, osmv1alpha1.CloudProviderAzure, osmv1alpha1.CloudProviderVsphere:
if external {
return false, true, nil
}

return true, false, nil

case osmv1alpha1.CloudProviderGoogle:
return true, false, nil
case osmv1alpha1.CloudProviderAWS,
osmv1alpha1.CloudProviderAzure,
osmv1alpha1.CloudProviderGoogle,
osmv1alpha1.CloudProviderVsphere:
return !external, external, nil

default:
return false, external, nil
Expand Down

0 comments on commit d9581af

Please sign in to comment.