-
Notifications
You must be signed in to change notification settings - Fork 2
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
ANXKUBE-1251: Allow setting hostname via annotation instead of IPs #355
Conversation
Code Climate has analyzed commit c2aab4c and detected 0 issues on this pull request. The test coverage on the diff in this pull request is 0.0% (50% is the threshold). This pull request will bring the total coverage in the repository to 56.8% (-0.6% change). View more on Code Climate. |
579b446
to
8d6d143
Compare
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.
Adjusted the code a bit, added documentation and aligned the name of the annotation with the other one.
8d6d143
to
d8130db
Compare
d8130db
to
c379f2d
Compare
Manually tested the changes with a From my point of view, this PR is ready for another review. |
Verified works :) |
By setting the hostname via an annotation on the given Service, we can workaround the shenanigans of kube-proxy to enable support for the PROXY protocol. In addition to the annotation being set, there's a configuration change needed by the LBaaS operators which is done manually right now. This change is also done by other CCM implementations, like the one of [DigitalOcean]. [DigitalOcean]: https://github.com/digitalocean/digitalocean-cloud-controller-manager/blob/d274be6e44f650311e4b960960b23001e6e513b4/cloud-controller-manager/do/loadbalancers.go#L236 Right now, this implementation is lacking proper tests to test this behaviour, which were skipped due to missing test infrastructure and a lack of time. Closes: ANXKUBE-1251 Co-authored-by: Zofia Hagenguth <[email protected]>
c379f2d
to
c2aab4c
Compare
Because the IP of the LoadBalancer Service is no longer exposed, it would get harder to setup DNS records. The current workaround would be: * Wait for the LoadBalancer to be reconciled without the annotation. * Write down the IP address to configure it elsewhere. * Annotate the service. This only works because there's a limitation of only one LoadBalancer per cluster at the moment. Yet, it can turn out to get problematic for any kind of automation. As such, we're exposing the hostname together with the IP. This also removes a lot of the code introduced in #355 and moves the code to its previous implementation. Closes: ANXKUBE-1280 See also: ANXKUBE-1251, #355
Because the IP of the LoadBalancer Service is no longer exposed, it would get harder to setup DNS records. The current workaround would be: * Wait for the LoadBalancer to be reconciled without the annotation. * Write down the IP address to configure it elsewhere. * Annotate the service. This only works because there's a limitation of only one LoadBalancer per cluster at the moment. Yet, it can turn out to get problematic for any kind of automation. As such, we're exposing the hostname together with the IP. This also removes a lot of the code introduced in #355 and moves the code to its previous implementation. Closes: ANXKUBE-1280 See also: ANXKUBE-1251, #355
Because the IP of the LoadBalancer Service is no longer exposed, it would get harder to setup DNS records. The current workaround would be: * Wait for the LoadBalancer to be reconciled without the annotation. * Write down the IP address to configure it elsewhere. * Annotate the service. This only works because there's a limitation of only one LoadBalancer per cluster at the moment. Yet, it can turn out to get problematic for any kind of automation. As such, we're exposing the hostname together with the IP. This also removes a lot of the code introduced in #355 and moves the code to its previous implementation. Closes: ANXKUBE-1280 See also: ANXKUBE-1251, #355
We want to allow setting a hostname on the LB instead of IPs, this is useful when using proxy-protocol in LBaaS.
Checklist
Unreleased
section in CHANGELOG.mdReferences
Community Note