Commit 2bad7e6b authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #39219 from liggitt/swagger-discovery

Automatic merge from submit-queue Include swaggerapi urls in system:discovery role Used by client side API validation and for client schema generation
parents 9b726d6b a209040a
......@@ -82,7 +82,7 @@ func ClusterRoles() []rbac.ClusterRole {
// a role which provides just enough power to discovery API versions for negotiation
ObjectMeta: api.ObjectMeta{Name: "system:discovery"},
Rules: []rbac.PolicyRule{
rbac.NewRule("get").URLs("/version", "/api", "/api/*", "/apis", "/apis/*").RuleOrDie(),
rbac.NewRule("get").URLs("/version", "/swaggerapi", "/swaggerapi/*", "/api", "/api/*", "/apis", "/apis/*").RuleOrDie(),
},
},
{
......
......@@ -383,6 +383,8 @@ items:
- /api/*
- /apis
- /apis/*
- /swaggerapi
- /swaggerapi/*
- /version
verbs:
- get
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment