-
Notifications
You must be signed in to change notification settings - Fork 242
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
Stop copying admin.conf to $HOME #936
Conversation
As $HOME is not always persisted (Flatcar/Coreos) Signed-off-by: Artiom Diomin <artiom@loodse.com>
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: kron4eg 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 |
/retest |
With this change, we would have to run all Why we don't just copy the kubeconfig when starting upgrade as well? That would be a simpler change that would also work with tmpfs. |
IDK ¯\_(ツ)_/¯, why to copy if we can not to copy? It's easy to loose track where is what and when, meaning: copying $KUBECONFIG around will have be an "always make sure it was done" operation or make assumption that it has been done. This PR fixes one such assumption which turned to be not true. On the other hand admin.conf location is well known and it's always there. |
/retest |
sudo KUBECONFIG=/etc/kubernetes/admin.conf \ | ||
kubectl drain {{ .NODE_NAME }} --ignore-daemonsets --delete-local-data |
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.
Can we make it consistent between addons and node scripts and use either flag or the environment variable?
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.
👍 done
That's true, but you also have to make sure that you don't forget a flag/environment variable when running kubectl commands and that you do it in a proper way. Copying would be done once at the beginning, like we do for the clientset anyways. However, I'm okay with whatever solution. I've left a comment on the PR if we go ahead with the proposed approach. |
Signed-off-by: Artiom Diomin <artiom@loodse.com>
/retest |
1 similar comment
/retest |
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.
/lgtm
LGTM label has been added. Git tree hash: 04a3b6e3f76984add8d364b6330772bf560211aa
|
What this PR does / why we need it:
Fixes bug on instances where $HOME is located on tmpfs and is not persisted across restarts.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #935
Special notes for your reviewer:
Does this PR introduce a user-facing change?: