Skip to content

Commit

Permalink
f
Browse files Browse the repository at this point in the history
  • Loading branch information
deads2k committed Aug 21, 2018
1 parent 0ed5d12 commit 28b885a
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const (
)

func BuildHandlerChain(genericConfig *genericapiserver.Config, kubeInformers informers.SharedInformerFactory, kubeAPIServerConfig *configapi.MasterConfig) (func(apiHandler http.Handler, kc *genericapiserver.Config) http.Handler, map[string]genericapiserver.PostStartHookFunc, error) {
extraPostStarkHooks := map[string]genericapiserver.PostStartHookFunc{}
extraPostStartHooks := map[string]genericapiserver.PostStartHookFunc{}

webconsoleProxyHandler, err := newWebConsoleProxy(kubeInformers, kubeAPIServerConfig)
if err != nil {
Expand All @@ -33,13 +33,13 @@ func BuildHandlerChain(genericConfig *genericapiserver.Config, kubeInformers inf
return nil, nil, err
}
for name, fn := range newPostStartHooks {
extraPostStarkHooks[name] = fn
extraPostStartHooks[name] = fn
}

return func(apiHandler http.Handler, genericConfig *genericapiserver.Config) http.Handler {
// Machinery that let's use discover the Web Console Public URL
accessor := newWebConsolePublicURLAccessor(genericConfig.LoopbackClientConfig)
extraPostStarkHooks["openshift.io-webconsolepublicurl"] = func(context genericapiserver.PostStartHookContext) error {
extraPostStartHooks["openshift.io-webconsolepublicurl"] = func(context genericapiserver.PostStartHookContext) error {
go accessor.Run(context.StopCh)
return nil
}
Expand All @@ -64,7 +64,7 @@ func BuildHandlerChain(genericConfig *genericapiserver.Config, kubeInformers inf

return handler
},
extraPostStarkHooks,
extraPostStartHooks,
nil
}

Expand Down

0 comments on commit 28b885a

Please sign in to comment.