Conversion webhook path failure with "the server could not find the requested resource" #2351
-
Hi, I'm having a problem with the webhook marker (referenced in Tutorial: Multi-Version API - The Kubebuilder Book). Environment~# kubebuilder version
Version: main.version{KubeBuilderVersion:"3.1.0", KubernetesVendor:"1.19.2", GitCommit:"92e0349ca7334a0a8e5e499da4fb077eb524e94a", BuildDate:"2021-05-27T17:54:28Z", GoOs:"linux", GoArch:"amd64"}
~# kubectl version
Client Version: version.Info{Major:"1", Minor:"20", GitVersion:"v1.20.4", GitCommit:"e87da0bd6e03ec3fea7933c4b5263d151aafd07c", GitTreeState:"clean", BuildDate:"2021-02-18T16:12:00Z", GoVersion:"go1.15.8", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"20", GitVersion:"v1.20.4", GitCommit:"e87da0bd6e03ec3fea7933c4b5263d151aafd07c", GitTreeState:"clean", BuildDate:"2021-02-18T16:03:00Z", GoVersion:"go1.15.8", Compiler:"gc", Platform:"linux/amd64"}
~# go version
go version go1.16.7 linux/amd64
controller-runtime - v0.8.3 Issue DescriptionI use the operator to maintain two versions of CRDs, where v1alpha1 is the hub and v1alpha2 is the spoke and set Then I set up the conversion file (both in v1alpha1 and v1alpha2) and the webhook file (in v1alpha2). In the webhook file, I set a webhook marker: Then I made the corresponding configuration in spec:
conversion:
strategy: Webhook
webhook:
clientConfig:
url: "https://<my_operator_server_address>:9443/{my_path}"
caBundle: {ca content with base64 encoded}
conversionReviewVersions:
- v1 However, when creating the v1alpha1 resource, the following error message appears. Error from server: error when creating "resource.yaml": conversion webhook for resource.io/v1alpha1, Kind=Test failed: the server could not find the requested resource Then I changed Is there something wrong with the Thx! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Hi @tpiperatgod, Would it still be an issue after the latest release? If so, let's create an issue based on this one so we can check it out. |
Beta Was this translation helpful? Give feedback.
-
Closing since it is answered. |
Beta Was this translation helpful? Give feedback.
Hi @tpiperatgod,
Would it still be an issue after the latest release? If so, let's create an issue based on this one so we can check it out.