mirror of
https://github.com/rancher/os.git
synced 2025-08-06 17:24:16 +00:00
Don't prompt for user input when we're not interactive
Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
This commit is contained in:
parent
7765a3308d
commit
fc1e4e060d
@ -154,7 +154,7 @@ func runInstall(image, installType, cloudConfig, device, kappend string, force,
|
||||
fmt.Printf("Installing from %s\n", image)
|
||||
|
||||
if !force {
|
||||
if !yes("Continue") {
|
||||
if util.IsRunningInTty() && !yes("Continue") {
|
||||
log.Infof("Not continuing with installation due to user not saying 'yes'")
|
||||
os.Exit(1)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user