Do not go into standalone mode when `--require-kubeconfig` is passed (fix #32085)

pull/6/head
Ilya Dmitrichenko 2016-09-05 19:50:44 +01:00
parent c4e2ade371
commit fe768dd405
1 changed files with 1 additions and 1 deletions

View File

@ -298,7 +298,7 @@ func initConfigz(kc *componentconfig.KubeletConfiguration) (*configz.Config, err
func run(s *options.KubeletServer, kubeDeps *kubelet.KubeletDeps) (err error) {
// TODO: this should be replaced by a --standalone flag
standaloneMode := (len(s.APIServerList) == 0)
standaloneMode := (len(s.APIServerList) == 0 && !s.RequireKubeConfig)
if s.ExitOnLockContention && s.LockFilePath == "" {
return errors.New("cannot exit on lock file contention: no lock file specified")