fix golint errors for pkg/master, together with cheftako

This commit is contained in:
mengyang02
2019-10-04 00:36:15 +08:00
parent 5fbda60c14
commit ed8767cded
6 changed files with 45 additions and 37 deletions

View File

@@ -31,6 +31,7 @@ import (
corev1client "k8s.io/client-go/kubernetes/typed/core/v1"
)
// ClientCARegistrationHook defines CA registration hook request structure
type ClientCARegistrationHook struct {
ClientCA []byte
@@ -41,6 +42,7 @@ type ClientCARegistrationHook struct {
RequestHeaderAllowedNames []string
}
// PostStartHook initializes client CA configmap for the API server
func (h ClientCARegistrationHook) PostStartHook(hookContext genericapiserver.PostStartHookContext) error {
// initializing CAs is important so that aggregated API servers can come up with "normal" config.
// We've seen lagging etcd before, so we want to retry this a few times before we decide to crashloop