Hey folks,
there are currently alerts about kserve's helm status being broken. Those happened after the Kubernetes 1.31 upgrade, here an example:
root@deploy2002:~# helm3 -n kserve history kserve
REVISION UPDATED STATUS CHART APP VERSION DESCRIPTION
1 Tue Feb 10 11:38:49 2026 deployed kserve-0.2.9 0.11.2 Install complete
2 Tue Feb 24 13:21:42 2026 superseded kserve-0.2.9 0.11.2 Upgrade "kserve" failed: cannot patch "inferenceservices.serving.kserve.io" with kind CustomResourceDefinition: CustomResourceDefinition.apiextensions.k8s.io "inferenceservices.serving.kserve.io" is invalid: spec.conversion.webhookClientConfig.caBundle: Invalid value: []byte{0xa}: unable to load root certificates: unable to parse bytes as PEM block
3 Tue Feb 24 13:21:47 2026 failed kserve-0.2.9 0.11.2 Rollback "kserve" failed: cannot patch "inferenceservices.serving.kserve.io" with kind CustomResourceDefinition: CustomResourceDefinition.apiextensions.k8s.io "inferenceservices.serving.kserve.io" is invalid: spec.conversion.webhookClientConfig.caBundle: Invalid value: []byte{0xa}: unable to load root certificates: unable to parse bytes as PEM block
4 Fri Feb 27 13:14:58 2026 superseded kserve-0.2.9 0.11.2 Upgrade "kserve" failed: cannot patch "inferenceservices.serving.kserve.io" with kind CustomResourceDefinition: CustomResourceDefinition.apiextensions.k8s.io "inferenceservices.serving.kserve.io" is invalid: spec.conversion.webhookClientConfig.caBundle: Invalid value: []byte{0xa}: unable to load root certificates: unable to parse bytes as PEM block
5 Fri Feb 27 13:15:03 2026 failed kserve-0.2.9 0.11.2 Rollback "kserve" failed: cannot patch "inferenceservices.serving.kserve.io" with kind CustomResourceDefinition: CustomResourceDefinition.apiextensions.k8s.io "inferenceservices.serving.kserve.io" is invalid: spec.conversion.webhookClientConfig.caBundle: Invalid value: []byte{0xa}: unable to load root certificates: unable to parse bytes as PEM blockWe don't explicitly override webhookClientConfig.caBundle in our yaml configs (the default is caBundle: Cg==), but we use the following injection in the KServe CRDs:
annotations: cert-manager.io/inject-ca-from: kserve/serving-cert
If you check kubectl edit crd inferenceservices.serving.kserve.io on any cluster you'll see that the value is not Cg==, but a valid base64-encoded PEM (the PKI root certificate - the right one). In https://github.com/metallb/metallb/issues/2679 people discuss a similar problem: it seems that K8s 1.31 got really strict about caBundle fields, it wants a valid PEM file.
The main issue IIUC in our case is that helm thinks Cg== is set, while cert-manager injects the right value behind the scenes.
We cannot keep things as they are, so we should find a solution:
- Maybe instead of Cg== we could create a dummy valid PEM string, and see how it goes.
- Upgrading the Kserve control plane to a new version may be more advisable, modulo keeping the compatibility with the current isvcs.
