-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Make Kubernetes aware of the LoadBalancer behaviour #1392
Conversation
Welcome @Sh4d1! |
Hi @Sh4d1. Thanks for your PR. I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/assign @caseydavenport |
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.
I'm an engineer with DigitalOcean (called out in the KEP's motivation section), and added some clarification in comments on the motivation.
1. Some cloud provider (DigitalOcean, Scaleway, ...) are using the LB's external IP as egress IP. This is a probem in the ipvs mode of kube proxy since the IP is bouded to an interface and healtchecks from the LB are never coming back. | ||
2. Some cloud provider are also having features at the LB level (TLS termination, PROXY protocol, ...) and bypassing the LB means missing these features when the packet arrives to the service (leading to protocols errors). | ||
|
||
So giving an options to these cloud to disable the actual beahviour would be very valuable. |
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.
One additional motivation:
Load-balancers which set status.loadBalancer.ingress[*].hostname
instead of setting status.loadBalancer.ingress[*].ip
don't exhibit this kube-proxy behavior. Because iptables/ipvs don't support rules based upon potentially dynamic hostnames, they leave the traffic untouched.
DigitalOcean has used this behavioral difference as a workaround the issue for customers who want to hairpin traffic through the LB (for example to get the ProxyProtocol headers appended). But it's hacky, and we much prefer the idea of addressing this functionality as the KEP proposes.
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.
Yep AWS does the same! Forgot to add it 😅
@caseydavenport @thockin the first draft looks good to me |
@thockin any updates on this? |
/ok-to-test |
b013220
to
46d6d37
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.
Great work! I've found some typos. I've crossed out and highlighted my suggestions to hopefully make it easier to make the changes. LGTM after you go through the comments 👍
0d81559
to
f63cb1d
Compare
Thanks for the review @MorrisLaw 😄 I think it's all resolved! |
@thockin any updates? I have a working code that seems to work 😄 Just need to choose the right naming! |
KEP is updated with a bit more detail. Not sure what else I can add, open to suggestions 😄
As stated at the end of the KEP, it works for managed solutions. If a user uses a self hosted cluster with a cloud's CCM, he then needs to be aware of the LB behaviour and act accordingly. That's why I tend to prefer the cloud controller manager solution. |
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.
I am OK with this - @uablrek can you say whether this speaks to your need?
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: Sh4d1, thockin The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@Sh4d1 can you squash your commits please? |
Signed-off-by: Patrik Cyvoct <patrik@ptrk.io>
0778bfa
to
615efc2
Compare
@andrewrynhard squashed! |
@andrewsykim ^ 🙂 |
Oh 🙄 totally sorry for that HL 😅 |
This should fit DigitalOcean's use case, lgtm 👍 |
/lgtm |
@tgraf You might want to track this, since you have a kube-proxy replacement. |
First draft of KEP to allow an option to change kube proxy behaviour regarding the LoadBalancer IPs
Signed-off-by: Patrik Cyvoct patrik@ptrk.io