mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 12:15:52 +00:00
Address review comments
This commit is contained in:
parent
9849079d4e
commit
781d7cf134
@ -64,6 +64,7 @@ const (
|
||||
)
|
||||
|
||||
// NewCloudControllerManagerCommand creates a *cobra.Command object with default parameters
|
||||
// initFuncConstructor is a map of named controller groups (you can start more than one in an init func) paired to their InitFuncConstructor.
|
||||
func NewCloudControllerManagerCommand(s *options.CloudControllerManagerOptions, cloudInitializer InitCloudFunc, initFuncConstructor map[string]InitFuncConstructor, stopCh <-chan struct{}) *cobra.Command {
|
||||
|
||||
cmd := &cobra.Command{
|
||||
|
@ -63,7 +63,7 @@ type Logger interface {
|
||||
// enough time to remove temporary files.
|
||||
func StartTestServer(t Logger, customFlags []string) (result TestServer, err error) {
|
||||
stopCh := make(chan struct{})
|
||||
configDoneCh := make(chan string)
|
||||
configDoneCh := make(chan struct{})
|
||||
var capturedConfig config.CompletedConfig
|
||||
tearDown := func() {
|
||||
close(stopCh)
|
||||
@ -90,7 +90,6 @@ func StartTestServer(t Logger, customFlags []string) (result TestServer, err err
|
||||
cloudInitializer := func(config *config.CompletedConfig) cloudprovider.Interface {
|
||||
capturedConfig = *config
|
||||
// send signal to indicate the capturedConfig has been properly set
|
||||
configDoneCh <- ""
|
||||
close(configDoneCh)
|
||||
cloudConfig := config.ComponentConfig.KubeCloudShared.CloudProvider
|
||||
cloud, err := cloudprovider.InitCloudProvider(cloudConfig.Name, cloudConfig.CloudConfigFile)
|
||||
|
Loading…
Reference in New Issue
Block a user