extending DefaultExternalHost for any registred cloud provider see #46567

pull/6/head
Yassine TIJANI 2017-06-06 13:40:21 +02:00
parent c0407972e9
commit 2eec2beed8
1 changed files with 1 additions and 2 deletions

View File

@ -54,8 +54,7 @@ func (s *CloudProviderOptions) DefaultExternalHost(genericoptions *genericoption
return nil
}
// TODO: extend for other providers
if s.CloudProvider == "gce" || s.CloudProvider == "aws" {
if cloudprovider.IsCloudProvider(s.CloudProvider) {
cloud, err := cloudprovider.InitCloudProvider(s.CloudProvider, s.CloudConfigFile)
if err != nil {
return fmt.Errorf("%q cloud provider could not be initialized: %v", s.CloudProvider, err)