-
Notifications
You must be signed in to change notification settings - Fork 101
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
Validate spec.ingress.http.path #313
Conversation
@ytsarev @somaritane - as we discussed. @kuritka It is cheap to cut off broken boject by api validation and not coplicate depresolver with essential data requirement. As for Ingress: we'll catch errors by same api validator, and throw an error, so broken object won't be created and controller won't observe it. |
If app doesn't start because |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good, just few comments.
Require .spec.ingress.http.path as it is required for gslb to function. If broken Gslb submitted, it will be rejected by openapi v3 validation. Same will happen when using Ingress annotations, we won't create broken Gslb object but log an error message instead. Signed-off-by: Dinar Valeev <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good just some comment on possible commented out config leftover
spec: | ||
rules: | ||
- host: notfound.cloud.example.com | ||
#http: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what is it for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a quick way to make it invalid for gslb controller, but keeping it visible.
Require .spec.ingress.http.path as it is required for gslb to function.
If broken Gslb submitted, it will be rejected by openapi v3 validation.
Same will happen when using Ingress annotations, we won't create broken
Gslb object but log an error message instead.
Signed-off-by: Dinar Valeev [email protected]