-
Notifications
You must be signed in to change notification settings - Fork 58
Fixed panic during kubeconfig generate #554
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
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #554 +/- ##
==========================================
+ Coverage 59.58% 59.67% +0.09%
==========================================
Files 56 56
Lines 5151 5158 +7
==========================================
+ Hits 3069 3078 +9
- Misses 1798 1799 +1
+ Partials 284 281 -3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
| } | ||
|
|
||
| if len(k3kService.Spec.Ports) == 0 { | ||
| logrus.Warn("No exposed port in LoadBalancer service.") |
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.
Should this be a different message from the one above?
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.
Do you mean that it could be the same message, like "No exposed ports in service."?
I'm not even sure you can have a Service without a Port actually.
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.
Oops...should've clarified this, you can't have a Service without a Port, spec.ports is a required value.
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.
Ah, awesome. So should I drop the check altogether? I'm fine with this, it simplify the code, and it was not really the reason of the PR. 🙂
Fix #432
When a Cluster is exposed with a LoadBalancer but the IP is not yet issued the Status of the Service is empty, because the ExternalIP is still in a
<pending>state.This PR adds a check, and logs a warning.