add a judgement for the cloud in server.go
Signed-off-by: PingWang <wang.ping5@zte.com.cn> update server.go Signed-off-by: PingWang <wang.ping5@zte.com.cn>
This commit is contained in:
		| @@ -348,8 +348,12 @@ func run(s *options.KubeletServer, kcfg *KubeletConfig) (err error) { | ||||
| 			if err != nil { | ||||
| 				return err | ||||
| 			} | ||||
| 			glog.V(2).Infof("Successfully initialized cloud provider: %q from the config file: %q\n", s.CloudProvider, s.CloudConfigFile) | ||||
| 			kcfg.Cloud = cloud | ||||
| 			if cloud == nil { | ||||
| 				glog.V(2).Infof("No cloud provider specified: %q from the config file: %q\n", s.CloudProvider, s.CloudConfigFile) | ||||
| 			} else { | ||||
| 				glog.V(2).Infof("Successfully initialized cloud provider: %q from the config file: %q\n", s.CloudProvider, s.CloudConfigFile) | ||||
| 				kcfg.Cloud = cloud | ||||
| 			} | ||||
| 		} | ||||
| 	} | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 PingWang
					PingWang