Run -y on remote topgrades if necessary

This commit is contained in:
Roey Darwish Dror
2020-06-19 22:29:28 +03:00
parent 13108cf603
commit 91ef904e57

View File

@@ -264,6 +264,10 @@ pub fn run_remote_topgrade(ctx: &ExecutionContext, hostname: &str) -> Result<()>
let env = format!("TOPGRADE_PREFIX={}", hostname);
args.extend(&["env", &env, "topgrade"]);
if ctx.config().yes() {
args.push("-y");
}
ctx.run_type().execute(&ssh).args(&args).check_run()
}
}