Skip to content
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

Fix/invert loadbalancer label on control planes #662

Conversation

mattanja
Copy link
Contributor

Hi, I can't find the "staging" branch mentioned in the contribution section of the readme, so I'm targeting master for now?

I've had the issue of the label node.kubernetes.io/exclude-from-external-load-balancers being set to true with allow_scheduling_on_control_plane=true in my configuration. After searching for the issue it seem to me that the conditions are not being set correctly.
There are two separate concerns mixed: the loadbalancer targeting the control planes (set via an "exclude" meaning inverted label) and the scheduling of load on the control planes (set via the ":NoSchedule" taint).

The condition for the loadbalancer label seems to have been inverted. (I'm not sure how it would have been possible that this was not detected before, which makes me doubt my solution.)

I have now tested the cluster setup with 3 control planes with allow_scheduling_on_control_plane=true and the label was set to node.kubernetes.io/exclude-from-external-load-balancers: "false" which should be correct. However, the LoadBalancer still did not target the servers. Maybe there are additional issues?

Before this, the label exclude-from-external-load-balancers is set to true on control planes even if allow_scheduling_on_control_plane is set to true in the kube.tf file.
@mysticaltech
Copy link
Collaborator

@mattanja Thanks for noticing, I will investigate and test your changes.

@mysticaltech mysticaltech merged commit 19ac940 into kube-hetzner:master Mar 21, 2023
1 check passed
@mattanja mattanja deleted the fix/invert-loadbalancer-label-on-control-planes branch March 21, 2023 11:11
@mysticaltech
Copy link
Collaborator

@mattanja Your fix was accurate! Thanks for this. It's been released in 1.10.6 🙏🚀

If you still do not see the control plane as target list, please try to see if there are any remaining NoSchedule taints on those. Normally there should not be when allow_scheduling_on_control_planes is set to true!

Let me know, and don't hesitate to open an issue to investigate this deeper, or provide an additional fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants