From c21ae87bd42352d6165ddea0cc5b15f0fa6fda47 Mon Sep 17 00:00:00 2001 From: Andrew Lavery Date: Mon, 25 Sep 2023 09:37:00 -0400 Subject: [PATCH] supply 'yes' flag to remote node commands (#4844) --- scripts/common/addon.sh | 4 ++-- scripts/common/upgrade.sh | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/common/addon.sh b/scripts/common/addon.sh index 07d17e17c0..c2f8bae19b 100644 --- a/scripts/common/addon.sh +++ b/scripts/common/addon.sh @@ -309,7 +309,7 @@ function addon_outro() { if [ "$AIRGAP" = "1" ]; then local command= command=$(printf "cat ./upgrade.sh | sudo bash -s airgap${common_flags}") - echo "$command" > "$DIR/remotes/allnodes" + echo "$command yes" > "$DIR/remotes/allnodes" printf "\n\t${GREEN}%s${NC}\n\n" "$command" else @@ -318,7 +318,7 @@ function addon_outro() { local command= command=$(printf "${prefix}upgrade.sh | sudo bash -s${common_flags}") - echo "$command" > "$DIR/remotes/allnodes" + echo "$command yes" > "$DIR/remotes/allnodes" printf "\n\t${GREEN}%s${NC}\n\n" "$command" fi diff --git a/scripts/common/upgrade.sh b/scripts/common/upgrade.sh index 467b863533..3b29800a9c 100644 --- a/scripts/common/upgrade.sh +++ b/scripts/common/upgrade.sh @@ -522,7 +522,7 @@ function upgrade_kubernetes_remote_node() { if [ "$AIRGAP" = "1" ]; then local command= command=$(printf "cat ./upgrade.sh | sudo bash -s airgap kubernetes-version=%s%s" "$targetK8sVersion" "$common_flags") - echo "$command" > "$DIR/remotes/$nodeName" + echo "$command yes" > "$DIR/remotes/$nodeName" printf "\t%b%s%b\n\n" "$GREEN" "$command" "$NC" else local prefix= @@ -530,7 +530,7 @@ function upgrade_kubernetes_remote_node() { local command= command=$(printf "%supgrade.sh | sudo bash -s kubernetes-version=%s%s" "$prefix" "$targetK8sVersion" "$common_flags") - echo "$command" > "$DIR/remotes/$nodeName" + echo "$command yes" > "$DIR/remotes/$nodeName" printf "\t%b %s%b\n\n" "$GREEN" "$command" "$NC" fi