catalog
catalog copied to clipboard
Failed to enable FluxCD due to invalid DNS name for `vela-core-webhook` service
Reproduction
> kubectl vela addon install fluxcd
Error: Internal error occurred: failed calling webhook "validating.core.oam.dev.v1beta1.applications": failed to call webhook: Post "https://vela-core-webhook.vela-system.svc:443/validating-core-oam-dev-v1beta1-applications?timeout=10s": context deadline exceeded
Error: exit status 1
Environment
KubeVela: 1.9.13 FluxCD Addon: 3.0.0 K8s: k3s v1.28 DNS: CoreDNS CNI: cilium
Problem
vela-core-webhook.vela-system.svc is an invalid hostname. In my cluster(k3s), there should be a cluster.local suffix as vela-core-webhook.vela-system.svc.cluster.local
I create a temp Pod to test it.
/ > nslookup velaux-server.vela-system.svc
Server: 10.43.0.10
Address: 10.43.0.10:53
** server can't find velaux-server.vela-system.svc: NXDOMAIN
** server can't find velaux-server.vela-system.svc: NXDOMAIN
/ > nslookup vela-core-webhook.vela-system.svc.cluster.local
Server: 10.43.0.10
Address: 10.43.0.10:53
Name: vela-core-webhook.vela-system.svc.cluster.local
Address: 10.43.111.182
However, there is no parameter to patch the URL.
I notice that the latest version supported by kubevela is 1.26. So I create a new v1.26 cluster by k3d with default config, and deploy kubevela and addons.
fluxcd still be failed to install after 600s timeout without any logs, in which other addons such as velaux can be installed successfully.
> kubectl vela addon install kubevela-io
Addon kubevela-io enabled successfully.
Please access addon-kubevela-io from the following endpoints:
+---------+-----------------------+------------------------------------+--------------------------------+-------+
| CLUSTER | COMPONENT | REF(KIND/NAMESPACE/NAME) | ENDPOINT | INNER |
+---------+-----------------------+------------------------------------+--------------------------------+-------+
| local | kubevela-io-resources | Service/vela-system/kubevela-io | http://kubevela-io.vela-system | true |
| local | kubevela-io-resources | Service/vela-system/kubevela-io-np | http://192.168.127.2:31536 | false |
+---------+-----------------------+------------------------------------+--------------------------------+-------+
> kubectl vela addon install fluxcd
⠏ Waiting addon application running. It is now in phase: runningWorkflow (timeout 277/600 seconds)...
Error: Enabling timeout, please run "vela status addon-fluxcd -n vela-system" to check the status of the addon
Error: exit status 1