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

Ensure charm only accesses local API server #176

Merged
merged 2 commits into from
Aug 26, 2021

Conversation

johnsca
Copy link
Contributor

@johnsca johnsca commented Aug 26, 2021

The new LB support in #153 unintentionally changed the endpoint that the charm client uses to talk to the API server making it use the internal LB address instead of always talking to the API server locally. This introduced an issue during bootstrap where the initial local-only token would try to be used on other API servers and fail.

Fixes lp:1941763

The new LB support in #153 unintentionally changed the endpoint that the
charm client uses to talk to the API server making it use the internal
LB address instead of always talking to the API server locally. This
introduced an issue during bootstrap where the initial local-only token
would try to be used on other API servers and fail.

Fixes [lp:1941763](https://bugs.launchpad.net/charm-kubernetes-master/+bug/1941763)
@johnsca
Copy link
Contributor Author

johnsca commented Aug 26, 2021

The runners are still down, but here's a test run I did locally against vSphere: https://pastebin.ubuntu.com/p/d7gRG92cB2/

Copy link
Contributor

@Cynerva Cynerva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The failure I explored on MAAS, where internal_url referred to an hacluster VIP, had a chicken-and-egg scenario. Services like kube-scheduler could not start because the VIP didn't route to masters, but the VIP didn't route because pacemaker saw that services like kube-scheduler were down and it refused to route to failing units.

To address the scenario with hacluster, I think we need to go further and use local_url everywhere that internal_url was used previously. Not just for the admin token, but also for kube-scheduler, kube-controller-manager, and kube-proxy.

@Cynerva Cynerva merged commit 82f8683 into master Aug 26, 2021
@Cynerva Cynerva deleted the johnsca/lp/1941763/local-api-only-self-access branch August 26, 2021 22:02
Cynerva pushed a commit that referenced this pull request Aug 26, 2021
* Ensure charm only accesses local API server

The new LB support in #153 unintentionally changed the endpoint that the
charm client uses to talk to the API server making it use the internal
LB address instead of always talking to the API server locally. This
introduced an issue during bootstrap where the initial local-only token
would try to be used on other API servers and fail.

Fixes [lp:1941763](https://bugs.launchpad.net/charm-kubernetes-master/+bug/1941763)

* Ensure all local charm kubectl usage uses the local url
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants