Skip to content

Commit 4007eed

Browse files
author
Kubernetes Submit Queue
authored
Merge pull request kubernetes#67694 from sttts/sttts-kube-apiserver-always-create-extension-apiserver-authentication
Automatic merge from submit-queue (batch tested with PRs 67694, 64973, 67902). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. kube-apiserver: always create configmap/extension-apiserver-authentication Other components (aggregated apiservers) read the configmap and fail hard if it does not exist. But they work without all fields being set (kubernetes#66394). In the future, components like ctrl-manager and scheduler won't need kube-apiserver to authenticate with them at all. So, consequently we should always create the file, even if it is empty. ```release-note Always create configmaps/extensions-apiserver-authentication from kube-apiserver. ```
2 parents 965df07 + d8bf802 commit 4007eed

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

pkg/master/client_ca_hook.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,11 +41,6 @@ type ClientCARegistrationHook struct {
4141
}
4242

4343
func (h ClientCARegistrationHook) PostStartHook(hookContext genericapiserver.PostStartHookContext) error {
44-
// no work to do
45-
if len(h.ClientCA) == 0 && len(h.RequestHeaderCA) == 0 {
46-
return nil
47-
}
48-
4944
// initializing CAs is important so that aggregated API servers can come up with "normal" config.
5045
// We've seen lagging etcd before, so we want to retry this a few times before we decide to crashloop
5146
// the API server on it.
@@ -68,7 +63,6 @@ func (h ClientCARegistrationHook) PostStartHook(hookContext genericapiserver.Pos
6863
}
6964

7065
return nil
71-
7266
}
7367

7468
// tryToWriteClientCAs is here for unit testing with a fake client. This is a wait.ConditionFunc so the bool

0 commit comments

Comments
 (0)