-
Notifications
You must be signed in to change notification settings - Fork 480
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
Use openshift base domain if ingress hostname is missing #2059
Conversation
000c1e5
to
191cddb
Compare
Signed-off-by: Pavol Loffay <[email protected]>
Signed-off-by: Pavol Loffay <[email protected]>
Signed-off-by: Pavol Loffay <[email protected]>
Signed-off-by: Pavol Loffay <[email protected]>
Signed-off-by: Pavol Loffay <[email protected]>
Signed-off-by: Pavol Loffay <[email protected]>
Signed-off-by: Pavol Loffay <[email protected]>
Signed-off-by: Pavol Loffay <[email protected]>
6a792c5
to
756ef72
Compare
Signed-off-by: Pavol Loffay <[email protected]>
Signed-off-by: Pavol Loffay <[email protected]>
Signed-off-by: Pavol Loffay <[email protected]>
@frzifus @jaronoff97 could you please review? |
if params.Instance.Spec.Ingress.Hostname == "" { | ||
domain, err := openshift.GetOpenShiftBaseDomain(context.Background(), params.Client) | ||
if err != nil { | ||
params.Recorder.Event(¶ms.Instance, "Error", "Normal", "Failed to get basedomain for Route.") |
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.
Does it make sense to return also an error in that case?
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.
That is a good question, if we error here the whole instance creation stops.
In the current implementation, the instance gets created, but the routes will fail, so I didn't change that.
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.
hm.. I assume failing early is good. May I ask, whats your thoughts on that @jaronoff97 ?
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.
hm.. I assume failing early is good. May I ask, whats your thoughts on that @jaronoff97 ?
For other resources, we follow the same approach: the instance is created, the "extra" resource is not but we log an error.
Docker image: docker.io/pavolloffay/opentelemetry-operator:dev-756ef72-1693233303
Updates: #1967
Updates: #1969