-
Notifications
You must be signed in to change notification settings - Fork 38.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add selfsubjectaccessreview API #31271
Conversation
@krousey I suspect that @ericchiang is a better fit given the area. I'm adding him. |
@@ -38,6 +38,10 @@ type SubjectAccessReview struct { | |||
Status SubjectAccessReviewStatus | |||
} | |||
|
|||
// +genclient=true | |||
// +nonNamespaced=true | |||
// +noMethods=true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I couldn't find documentation on what +noMethods
accomplishes. Does it limit the actions generated to "Create"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I couldn't find documentation on what +noMethods accomplishes. Does it limit the actions generated to "Create"?
It prevents the client generator from generating methods. Since this isn't a normal resource, it doesn't have types for things like SelfSubjectAccessReviewList
(no get method), so the default generator fails.
It means you have to manually create the Create
methods in the generated_expansion.go file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It means you have to manually create the Create methods in the generated_expansion.go file.
Nice. Does that not get overridden as soon as someone else regenerates? (not to get too off topic)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice. Does that not get overridden as soon as someone else regenerates? (not to get too off topic)
No, it is preserved.
Don't know what's up with the integration tests but lgtm |
Can one of the admins verify that this patch is reasonable to test? If so, please reply "ok to test". This message will repeat several times in short succession due to jenkinsci/ghprb-plugin#292. Sorry. |
GCE e2e build/test passed for commit 2f642eb. |
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
GCE e2e build/test passed for commit 2f642eb. |
Automatic merge from submit-queue |
Exposes the REST API for self subject access reviews. This allows a user to see whether or not they can perform a particular action.
@kubernetes/sig-auth
This change is![Reviewable](https://camo.githubusercontent.com/2d899f4291d07d3cd2fa4aaae1e3b243f164c23fce87d30a589ace0d496a444c/68747470733a2f2f72657669657761626c652e6b756265726e657465732e696f2f7265766965775f627574746f6e2e737667)