mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-27 05:27:21 +00:00
Merge pull request #46212 from CaoShuFeng/RBACSuperUser
Automatic merge from submit-queue (batch tested with PRs 46394, 46650, 46436, 46673, 46212) Remove deprecated variable RBACSuperUser authorization-rbac-super-user is deprecated now. So we can remove the vaiable. Further more the comment about this variable is wrong. Remove them also. **Release note**: ```NONE ```
This commit is contained in:
commit
77a8c25839
@ -54,11 +54,6 @@ type AuthorizationConfig struct {
|
|||||||
// TTL for caching of unauthorized responses from the webhook server.
|
// TTL for caching of unauthorized responses from the webhook server.
|
||||||
WebhookCacheUnauthorizedTTL time.Duration
|
WebhookCacheUnauthorizedTTL time.Duration
|
||||||
|
|
||||||
// Options for RBAC
|
|
||||||
|
|
||||||
// User which can bootstrap role policies
|
|
||||||
RBACSuperUser string
|
|
||||||
|
|
||||||
InformerFactory informers.SharedInformerFactory
|
InformerFactory informers.SharedInformerFactory
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -167,9 +162,6 @@ func (config AuthorizationConfig) New() (authorizer.Authorizer, error) {
|
|||||||
if !authorizerMap[modes.ModeWebhook] && config.WebhookConfigFile != "" {
|
if !authorizerMap[modes.ModeWebhook] && config.WebhookConfigFile != "" {
|
||||||
return nil, errors.New("Cannot specify --authorization-webhook-config-file without mode Webhook")
|
return nil, errors.New("Cannot specify --authorization-webhook-config-file without mode Webhook")
|
||||||
}
|
}
|
||||||
if !authorizerMap[modes.ModeRBAC] && config.RBACSuperUser != "" {
|
|
||||||
return nil, errors.New("Cannot specify --authorization-rbac-super-user without mode RBAC")
|
|
||||||
}
|
|
||||||
|
|
||||||
return union.New(authorizers...), nil
|
return union.New(authorizers...), nil
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user