Skip to content

Final kubeadm-kubelet integration refactor PR#64624

Merged
k8s-github-robot merged 2 commits intokubernetes:masterfrom
luxas:kubeadm_kubelet_final
Jun 7, 2018
Merged

Final kubeadm-kubelet integration refactor PR#64624
k8s-github-robot merged 2 commits intokubernetes:masterfrom
luxas:kubeadm_kubelet_final

Conversation

@luxas
Copy link
Copy Markdown
Member

@luxas luxas commented Jun 1, 2018

What this PR does / why we need it:
Note: Work in progress
This PR:

  • Updates the debs/rpms to do the "right thing" with the new integration flow
  • Uploads the CRISocket information to the Node object as an annotation
  • Makes the kubeadm init / kubeadm join flow to be preflight, stop kubelet, write config/env files, daemon-reload, start kubelet
  • Renames .NodeRegistration.ExtraArgs to .NodeRegistration.KubeletExtraArgs as discussed in the SIG meeting
  • Adds a kubeadm upgrade node config command for fetching the latest configuration and writing it down to the node before upgrading the kubelet
  • Makes dynamic kubelet config actually get enabled when the feature gate in kubeadm is specifically opted into by the user
  • Fixes misc. minor bugs
  • Makes sure kubeadm init --dry-run works, so the dry-run functionality works for the kubelet integration as well

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 kubernetes/kubeadm#848

Special notes for your reviewer:

Release note:

kubeadm: Add a new `kubeadm upgrade node config` command

@kubernetes/sig-cluster-lifecycle-pr-reviews

@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. area/kubeadm labels Jun 1, 2018
@k8s-ci-robot k8s-ci-robot requested review from jbeda and lavalamp June 1, 2018 18:32
@luxas luxas requested review from fabriziopandini, kad, liztio and timothysc and removed request for jbeda and lavalamp June 1, 2018 18:32
Copy link
Copy Markdown
Contributor

@chuckha chuckha left a comment

Choose a reason for hiding this comment

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

Looking forward to having this.

Please fix the glog issues then it's 👍from me.

In general, do not use glog.Infof/ln and favor fmt.Printf/ln. If you want it to not show up by default, use glog.V(x).Infof/ln.

The bare glog.Info calls are responsible for the gross default log output.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This applies to all uses of glog.Info{f,ln}
Either use glog as a glog.V(x).Infoln or fmt.Println

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I'm gonna wait for your PR to merge, rebase and then fixup this (which then gets easier, given your PR merges tonight)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This seems like an error instead of a warning, unless there's a way we can recover automatically from this failure?

Additionally, instead of using glog.Warningf, please add a warning prefix and use fmt.Println. Or if you feel like warning isn't the right level, use fmt.Printf or glog.V(x).Infof

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

godoc this please

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

done

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

accidentally the rest of the sentence

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

done

Copy link
Copy Markdown
Contributor

@timothysc timothysc left a comment

Choose a reason for hiding this comment

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

1st pass feedback

/cc @kad

b/c he had opinions earlier.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

? - this seems misplaced to me.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

kubeletVersion is needed for the dynamic config func. This execs out to the kubelet to determine what version to target. This func call just moved to where it's actually used

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I don't know how I feel about this vs. under the config subcommand.

UX is inconsistent for configs

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

This is gonna be pretty similar to kubeadm phase kubelet config download. WDYT?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Um then we should call this f(n) restart.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

oops should be .ServiceStop here. fixed

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 2, 2018
@timothysc timothysc added this to the v1.11 milestone Jun 4, 2018
@timothysc timothysc added priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. kind/feature Categorizes issue or PR as related to a new feature. status/approved-for-milestone labels Jun 4, 2018
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

this needs to be =-, not -=

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Thanks, fixed!

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

=-

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

done

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

=-

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

done

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

=-

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

done

@luxas luxas force-pushed the kubeadm_kubelet_final branch from cdc6e5b to 7964d7c Compare June 4, 2018 22:14
@k8s-ci-robot k8s-ci-robot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Jun 4, 2018
@fejta-bot
Copy link
Copy Markdown

/retest
This bot automatically retries jobs that failed/flaked on approved PRs (send feedback to fejta).

Review the full test history for this PR.

Silence the bot with an /lgtm cancel comment for consistent failures.

1 similar comment
@fejta-bot
Copy link
Copy Markdown

/retest
This bot automatically retries jobs that failed/flaked on approved PRs (send feedback to fejta).

Review the full test history for this PR.

Silence the bot with an /lgtm cancel comment for consistent failures.

@timothysc
Copy link
Copy Markdown
Contributor

/test pull-kubernetes-e2e-gce

@fejta-bot
Copy link
Copy Markdown

/retest
This bot automatically retries jobs that failed/flaked on approved PRs (send feedback to fejta).

Review the full test history for this PR.

Silence the bot with an /lgtm cancel comment for consistent failures.

1 similar comment
@fejta-bot
Copy link
Copy Markdown

/retest
This bot automatically retries jobs that failed/flaked on approved PRs (send feedback to fejta).

Review the full test history for this PR.

Silence the bot with an /lgtm cancel comment for consistent failures.

@luxas luxas force-pushed the kubeadm_kubelet_final branch from 7d3592b to d60aa40 Compare June 6, 2018 20:25
@k8s-ci-robot k8s-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Jun 6, 2018
@luxas
Copy link
Copy Markdown
Member Author

luxas commented Jun 6, 2018

(as part of the rebase, I added more unit test cases in cmd/kubeadm/app/phases/kubelet/flags_test.go, which made this go XXL)

@luxas luxas force-pushed the kubeadm_kubelet_final branch from d60aa40 to 7a87cf1 Compare June 6, 2018 20:41
@neolit123
Copy link
Copy Markdown
Member

/test pull-kubernetes-e2e-gce

@neolit123
Copy link
Copy Markdown
Member

re-adding
/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jun 6, 2018
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

Approval requirements bypassed by manually added approval.

This pull-request has been approved by: fabriziopandini, luxas, neolit123, timothysc

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-github-robot
Copy link
Copy Markdown

[MILESTONENOTIFIER] Milestone Pull Request: Up-to-date for process

@fabriziopandini @luxas @neolit123 @timothysc

Pull Request Labels
  • sig/cluster-lifecycle: Pull Request will be escalated to these SIGs if needed.
  • priority/critical-urgent: Never automatically move pull request out of a release milestone; continually escalate to contributor and SIG through all available channels.
  • kind/feature: New functionality.
Help

@neolit123
Copy link
Copy Markdown
Member

/test pull-kubernetes-kubemark-e2e-gce

@neolit123
Copy link
Copy Markdown
Member

/test pull-kubernetes-kubemark-e2e-gce
/test pull-kubernetes-e2e-gce

@k8s-github-robot
Copy link
Copy Markdown

/test all [submit-queue is verifying that this PR is safe to merge]

@neolit123
Copy link
Copy Markdown
Member

/test pull-kubernetes-node-e2e

@k8s-github-robot
Copy link
Copy Markdown

Automatic merge from submit-queue (batch tested with PRs 63386, 64624, 62297, 64847). If you want to cherry-pick this change to another branch, please follow the instructions here.

@k8s-github-robot k8s-github-robot merged commit 61a5809 into kubernetes:master Jun 7, 2018
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

k8s-ci-robot commented Jun 7, 2018

@luxas: The following tests failed, say /retest to rerun them all:

Test name Commit Details Rerun command
pull-kubernetes-integration 7a87cf1 link /test pull-kubernetes-integration
pull-kubernetes-e2e-gce 7a87cf1 link /test pull-kubernetes-e2e-gce

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Details

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. I understand the commands that are listed here.

@zparnold
Copy link
Copy Markdown

Hello there! @luxas I'm Zach Arnold working on Docs for the 1.11 release. This PR was identified as one needing some documentation in the https://github.com/kubernetes/website repo around your contributions (thanks by the way!) When you have some time, could you please modify/add/remove the relevant content that needs changing in our documentation repo? Thanks! Please let me or my colleague Misty know (@zparnold/@misty on K8s Slack) if you need any assistance with the documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. area/kubeadm cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/feature Categorizes issue or PR as related to a new feature. lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now. release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create a kubeadm upgrade node config command