[Docs/book] running webhook (config/default/kustomization.yaml) not working #3426
Labels
kind/bug
Categorizes issue or PR as related to a bug.
kind/documentation
Categorizes issue or PR as related to documentation.
What broke? What's expected?
I was following the kubebuilder book to add a validation webhook to my operator project (scaffolded using operator-sdk).
The docs at kubebuilder book says that "You need to enable the webhook and cert manager configuration through kustomize. config/default/kustomization.yaml should now look like the following:"
I replaced the contents of my kustomization.yaml with this (also changed the namespace and namePrefix for my project). However, after following the complete instructions and deploying the operator using
make deploy
I got this error in the controller manager pods:2023-05-22T03:06:20Z ERROR setup problem running manager {"error": "open /tmp/k8s-webhook-server/serving-certs/tls.crt: no such file or directory"} main.main /workspace/main.go:123 runtime.main /usr/local/go/src/runtime/proc.go:250
After some basic debugging I observed that the line
#- manager_webhook_patch.yaml
in the fileconfig/default/kustomization.yaml
is commented in the kubebuilder book. I uncommented it and redeployed the operator and it worked.Reproducing this issue
No response
KubeBuilder (CLI) Version
I'm using operator-sdk
PROJECT version
No response
Plugin versions
No response
Other versions
No response
Extra Labels
/kind documentation
The text was updated successfully, but these errors were encountered: