-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
IstioControlPlaneSpec Version validation pattern too wide #808
Comments
Hi @Tanemahuta, Thanks for the PR! Could you please elaborate on what was your issue? What was the exact IstioControlPlane CR that you used and what issue exactly did you get? Because we are not aware of such issue right now. Having said that your PR might make sense anyway, we'll review it, we just would like to understand the root issue as well. |
Sure. I tried to deploy the operator (chart 2.0.6) and a controlplane cr. |
You should be able to deploy this: https://github.com/banzaicloud/istio-operator/blob/release-1.11/config/samples/servicemesh_v1alpha1_istiocontrolplane.yaml#L6 |
So it only needs to be started with |
I have tried that, but the pattern is matched to the full string. Please believe me, i have tried to use 1.11, but the k8s API threw a validation error. I modified the CRD locally and: kazam, it worked. |
what was the error the apiserver threw? The |
@Laci21 and @waynz0r, It was my editor throwing an invalid error when validating the CR against the CRD (seems like the regex was matched against the complete string instead of finding a single match). When I deployed the spec with (Sorry, exhausting week for me, obviously) I still have two requests:
My solutions:
Cheers, |
Hi Christian, Let me answer to your requests:
Summing up, everything is deliberate as it is today. Let us know if you have questions, issues with any of the approaches, we are open to suggestions. Laszlo |
Also, the IstioControlPlane CRD is backward compatible as well, which is why the version is used as |
@Laci21 , please read the issue description again. The dot in the regex needs to be escaped, that's what I modified my PR to do. |
My bad, you are completely right, that is indeed a bug, thanks for catching and fixing it! |
Fixed in #809. |
Describe the bug
The regex validating the version of IstioControlPlaneSpec.Version is too wide. The
.
should be escaped.Steps to reproduce the issue:
Deploy operator chart version 2.0.5. Add a IstioControlPlane with
Expected behavior
Validation fails in the k8s API.
The text was updated successfully, but these errors were encountered: