准备将 k8s 网络组件 calico 从 3.22 升级至 3.23,在部署新版清单文件时报错
for: "calico.yaml": CustomResourceDefinition.apiextensions.k8s.io "ipamblocks.crd.projectcalico.org" is invalid: spec.preserveUnknownFields: Invalid value: true: must be false in order to use defaults in the schema
请问如何解决?
在 CRD fails to apply on upgrade - preserveUnknownFields must be false in order to use defaults 的 issue 回复中找到了解决方法:
报错的清单部分添加 preserveUnknownFields: false