Merge pull request #112175 from chendave/fix_early_return

kubeadm: too early return for reset with dry-run or force mode
This commit is contained in:
Kubernetes Prow Robot 2022-09-01 03:09:08 -07:00 committed by GitHub
commit cba0dcecc9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -53,7 +53,9 @@ func runPreflight(c workflow.RunData) error {
if !r.ForceReset() && !r.DryRun() {
klog.Warning("[reset] WARNING: Changes made to this host by 'kubeadm init' or 'kubeadm join' will be reverted.")
return util.InteractivelyConfirmAction("reset", "Are you sure you want to proceed?", r.InputReader())
if err := util.InteractivelyConfirmAction("reset", "Are you sure you want to proceed?", r.InputReader()); err != nil {
return err
}
}
fmt.Println("[preflight] Running pre-flight checks")