Skip to content
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

admission controller types #477

Closed
clux opened this issue Mar 27, 2021 · 1 comment · Fixed by #484
Closed

admission controller types #477

clux opened this issue Mar 27, 2021 · 1 comment · Fixed by #484
Labels
api Api abstraction related help wanted Not immediately prioritised, please help!

Comments

@clux
Copy link
Member

clux commented Mar 27, 2021

AdmissionReview / AdmissionRequest / AdmissionResponse do not have generated types in k8s-openapi.

This is possibly (speculation) for good reasons; the way they work is very different from a normal api call: https://kubernetes.io/blog/2019/03/21/a-guide-to-kubernetes-admission-controllers/

The types however are present in kuberenetes/api/admission, and don't see how people can do admission controllers without them.

I imagine we could provide a module that hand-rolled those structs, make them generic over the Resource trait, and it might not be that bad?

Have not had much time to look at this, but it could be a nice clean feature for someone to try, and am happy to review PRs. Marking as help wanted, but it's probably not easy.

Testing wise, a web server would pull in a lot of deps, but maybe we could do something light with warp or hyper as an example.

@clux clux added help wanted Not immediately prioritised, please help! api Api abstraction related labels Mar 27, 2021
olix0r added a commit to olix0r/polixy that referenced this issue Mar 27, 2021
There's apparently no good way to do admission controllers in kube-rs at
the moment. See kube-rs/kube#477
coadler added a commit to coadler/kube-rs that referenced this issue Mar 31, 2021
coadler added a commit to coadler/kube-rs that referenced this issue Mar 31, 2021
coadler added a commit to coadler/kube-rs that referenced this issue Mar 31, 2021
coadler added a commit to coadler/kube-rs that referenced this issue Mar 31, 2021
@clux clux closed this as completed in #484 Mar 31, 2021
@clux
Copy link
Member Author

clux commented May 15, 2021

This is now officially released in 0.53. Though it did receive a number of minor tweaks in master from #488, #498, #499, #507, #509.

Thanks again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Api abstraction related help wanted Not immediately prioritised, please help!
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant