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

docs: Automated CherryPick Update for release-v4.4 #3915

Merged
merged 1 commit into from Sep 13, 2023

Conversation

sealos-ci-robot
Copy link
Member

@sealos-ci-robot sealos-ci-robot commented Sep 13, 2023

πŸ€– Generated by Copilot at 7064d13

Summary

πŸ—‘οΈβš™οΈπŸ›

This pull request enhances the reset functionality of sealos for both k3s and kubernetes clusters. It ensures that the kubeconfig file is properly deleted from the nodes' home directories before resetting them.

No trace of the old cluster, we wipe it from the node
We use the $HOME variable, we know the right abode
We execute before reset, we don't leave room for error
We reinstall k3s, we are the cluster terror

Walkthrough

  • Remove kubeconfig file from node before resetting it to avoid conflicts or errors when reinstalling k3s or kubernetes (link, link, link, link)
    • Use $HOME environment variable instead of relative path .kube for removeKubeConfig command in pkg/runtime/kubernetes/reset.go (link)
    • Execute removeKubeConfig command in pkg/runtime/k3s/lifecycle.go before calling resetNode function from kubernetes package (link)
    • Remove redundant removeKubeConfig command from resetNode function in pkg/runtime/kubernetes/reset.go (link)
    • Add removeKubeConfig command to resetNode function in pkg/runtime/kubernetes/reset.go for nodes that are not running k3s (link)

Automated changes by create-pull-request GitHub action

Signed-off-by: cuisongliu <cuisongliu@qq.com>
@codecov
Copy link

codecov bot commented Sep 13, 2023

Codecov Report

Patch has no changes to coverable lines.

πŸ“’ Thoughts on this report? Let us know!.

@cuisongliu cuisongliu added this to the cherry-pick milestone Sep 13, 2023
@cuisongliu cuisongliu merged commit 8c4ccb7 into release-v4.4 Sep 13, 2023
137 checks passed
@cuisongliu cuisongliu deleted the cherry-pick-release-v4.4-3911 branch September 13, 2023 03:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants