Skip to content

Commit 57d3020

Browse files
committed
Fix make install
Running `make install` fails with error: The CustomResourceDefinition "openstackcontrolplanes.core.openstack.org" is invalid: metadata.annotations: Too long: must have at most 262144 bytes This patch fixes this problem by using `kubectl replace` instead of `kubectl apply`. Replace was chosen over `kubectl apply --server-side` because the apply may fail to merge with the existing CRD, whereas replace will not fail.
1 parent 92d942c commit 57d3020

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ endif
188188

189189
.PHONY: install
190190
install: manifests kustomize ## Install CRDs into the K8s cluster specified in ~/.kube/config.
191-
$(KUSTOMIZE) build config/crd | kubectl apply -f -
191+
$(KUSTOMIZE) build config/crd | kubectl replace -f -
192192

193193
.PHONY: uninstall
194194
uninstall: manifests kustomize ## Uninstall CRDs from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion.

0 commit comments

Comments
 (0)