k8up-io / k8up

Kubernetes and OpenShift Backup Operator
https://k8up.io/
Apache License 2.0
717 stars 66 forks source link

CRD Installation failed 4.7.0 #977

Open matthiasbaldi opened 6 months ago

matthiasbaldi commented 6 months ago

Description

The CRD installation will fail when I try to apply it like documented: kubectl apply -f https://github.com/k8up-io/k8up/releases/download/k8up-4.7.0/k8up-crd.yaml

Additional Context

No response

Logs

kubectl apply -f https://github.com/k8up-io/k8up/releases/download/k8up-4.7.0/k8up-crd.yaml                       
customresourcedefinition.apiextensions.k8s.io/archives.k8up.io unchanged
customresourcedefinition.apiextensions.k8s.io/backups.k8up.io unchanged
customresourcedefinition.apiextensions.k8s.io/checks.k8up.io unchanged
customresourcedefinition.apiextensions.k8s.io/prunes.k8up.io unchanged
customresourcedefinition.apiextensions.k8s.io/restores.k8up.io unchanged
customresourcedefinition.apiextensions.k8s.io/schedules.k8up.io unchanged
customresourcedefinition.apiextensions.k8s.io/snapshots.k8up.io unchanged
Error from server (Invalid): error when creating "https://github.com/k8up-io/k8up/releases/download/k8up-4.7.0/k8up-crd.yaml": CustomResourceDefinition.apiextensions.k8s.io "podconfigs.k8up.io" is invalid: metadata.annotations: Too long: must have at most 262144 bytes
Error from server (Invalid): error when creating "https://github.com/k8up-io/k8up/releases/download/k8up-4.7.0/k8up-crd.yaml": CustomResourceDefinition.apiextensions.k8s.io "prebackuppods.k8up.io" is invalid: metadata.annotations: Too long: must have at most 262144 bytes

Expected Behavior

What in my case worked was the ---server-side suffix. kubectl apply -f https://github.com/k8up-io/k8up/releases/download/k8up-4.7.0/k8up-crd.yaml --server-side

It should work out of the box, may shorten the metadata or change the docs to the server-side flag.

Steps To Reproduce

No response

Version of K8up

4.7.0

Version of Kubernetes

1.27.10

Distribution of Kubernetes

Kubernetes

timatlee commented 6 months ago

Same output for me. Fix from a previous issue is to include --server-side in the kubectl command:

kubectl apply -f https://github.com/k8up-io/k8up/releases/download/k8up-4.7.0/k8up-crd.yaml --server-side

Kidswiss commented 5 months ago

Hi @matthiasbaldi

Can you point us to the location in the docs where you found the outdated instructions?

matthiasbaldi commented 5 months ago

@Kidswiss yes of course - sorry :wink: https://github.com/k8up-io/k8up/tree/master/charts/k8up#installation