vernemq / vmq-operator

VerneMQ Operator creates/configures/manages VerneMQ clusters atop Kubernetes
Apache License 2.0
30 stars 20 forks source link

apiextensions.k8s.io/v1beta1 deprecated Operator cannot deploy on k8s >1.22 #27

Open psarossy opened 2 years ago

psarossy commented 2 years ago

The operator config uses deprecated features, and hence doesn't work on anything newer than k8s 1.22

$ kubectl delete -f only_vernemq [13:51:56] namespace "messaging" deleted deployment.apps "vmq-operator" deleted role.rbac.authorization.k8s.io "vmq-operator" deleted rolebinding.rbac.authorization.k8s.io "vmq-operator" deleted serviceaccount "vmq-operator" deleted service "vernemq-k8s" deleted serviceaccount "vernemq-k8s" deleted unable to recognize "only_vernemq/0vernemq-operator-0vernemqCustomResourceDefinition.yaml": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1beta1" unable to recognize "only_vernemq/vernemq-vernemq.yaml": no matches for kind "VerneMQ" in version "vernemq.com/v1alpha1"

ioolkos commented 2 years ago

@psarossy Thanks, yes, that's likely so. Do you have a need for this? What is expected or best practice to support Kubernetes versions?

thatsdone commented 2 years ago

I also noticed this issue today.

IMHO, expected behavior is working for the latest version of kubernetes even if we got deprecation wornings. Also, the best practice would be updating implementation before stop serving timing.

According to the "Deprecated API Migration Guide":

https://kubernetes.io/docs/reference/using-api/deprecation-guide/

at least CustomResourceDefinition API version should be updated to v1 from v1beta1.

wer-is-paul commented 2 years ago

Should bei fixed by the Operator SDK Update, pleased retest