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

webhook for delete verb is broken #1278

Closed
felipeweb opened this issue Nov 29, 2020 · 7 comments
Closed

webhook for delete verb is broken #1278

felipeweb opened this issue Nov 29, 2020 · 7 comments
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.

Comments

@felipeweb
Copy link

felipeweb commented Nov 29, 2020

when I run kubectl delete -f config/samples/app_v1alpha1_helmrelease.yaml I receive response below

Error from server: error when deleting "config/samples/app_v1alpha1_helmrelease.yaml": admission webhook "mhelmrelease.undistro.io" denied the request: there is no content to decode running on kind v0.9.0 go1.15.2 linux/amd64 , using sigs.k8s.io/controller-runtime v0.7.0-alpha.6 and controller-gen v0.4.1 with CRD v1

@felipeweb felipeweb changed the title Delete validation for Validator interface is broken webhook for delete verb is broken Nov 29, 2020
@klzsysy
Copy link

klzsysy commented Dec 16, 2020

same here

  • v1.19.2-1008
  • kubebuilder@2.3.1
  • controller-gen@v0.4.1

go.mod:

	k8s.io/apimachinery v0.18.6
	k8s.io/client-go v0.18.6
	k8s.io/kube-openapi v0.0.0-20200410145947-bcb3869e6f29 // indirect
	sigs.k8s.io/controller-runtime v0.6.3
	sigs.k8s.io/controller-tools v0.4.1 // indirect
	sigs.k8s.io/structured-merge-diff v1.0.1-0.20191108220359-b1b620dd3f06 // indirect

Error from server: admission webhook "mmodule.kb.io" denied the request: there is no content to decode

@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

Send feedback to sig-contributor-experience at kubernetes/community.
/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Mar 16, 2021
@christopherhein
Copy link
Member

Did you all work around this? It seems like it's just that the decoder package only looks at req.Object not req.OldObject as is present with admission deletes.

@fejta-bot
Copy link

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.

If this issue is safe to close now please do so with /close.

Send feedback to sig-contributor-experience at kubernetes/community.
/lifecycle rotten

@k8s-ci-robot k8s-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels May 6, 2021
@christopherhein
Copy link
Member

/close

@k8s-ci-robot
Copy link
Contributor

@christopherhein: Closing this issue.

In response to this:

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@grzesuav
Copy link

I hit that recently and needed to navigate to solution - use DecodeRaw method and passing just oldObject

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.
Projects
None yet
Development

No branches or pull requests

6 participants