diff options
author | Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org> | 2023-05-28 07:09:09 +0000 |
---|---|---|
committer | Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org> | 2023-05-31 14:42:09 +0000 |
commit | 07abfde7532f585b7eaeb86077fbd35e00842cd0 (patch) | |
tree | 69708fb46a8cb37a7bb809460054923ff07b1cf2 /tcwg-benchmark.sh | |
parent | 7970c7fdae84e58f697cce9e59559cbecdceac47 (diff) |
jenkins-helpers.sh (wait_for_ssh_server): Allow more ssh options
... as parameters, not just ssh port. This is necessary for
upcoming patches.
Change-Id: I988c263bc0732b451ed208033cfb5eb6225d35b5
Diffstat (limited to 'tcwg-benchmark.sh')
-rwxr-xr-x | tcwg-benchmark.sh | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tcwg-benchmark.sh b/tcwg-benchmark.sh index 863079e6..531412eb 100755 --- a/tcwg-benchmark.sh +++ b/tcwg-benchmark.sh @@ -312,13 +312,13 @@ while [ $tries_left != 0 ]; do if timeout 1m ssh "$boardname" true; then ssh_cmd="ssh" - wait_opts="" + wait_opts=() elif timeout 1m ssh -p22 -lroot "$boardname" true; then ssh_cmd="ssh -p22 -lroot" - wait_opts="22 -lroot" + wait_opts=(-p22 -lroot) else ssh_cmd="false" - wait_opts="22 -lroot" + wait_opts=(-p22 -lroot) reboot=true force_power_cycle=true tries_left=0 @@ -348,7 +348,7 @@ while [ $tries_left != 0 ]; do pdu_name=$(echo "${boardname%.tcwglab}" \ | sed -e 's/^tcwg-bmk-/tcwg-/') nvidia-power-cycle.sh "$pdu_name" - wait_for_ssh_server "$boardname" "$wait_opts" 150 + wait_for_ssh_server "$boardname" 150 "${wait_opts[@]}" ) & wait $! || exit $EXTERNAL_FAIL echo "Successfully powered-cycled $boardname" @@ -362,7 +362,7 @@ while [ $tries_left != 0 ]; do # Wait until the ssh server is ready sleep 30 # Give time to the board to shutdown - wait_for_ssh_server "$boardname" "$wait_opts" 150 & + wait_for_ssh_server "$boardname" 150 "${wait_opts[@]}" & ret=0 && wait $! || ret=$? if [ $ret != 0 ]; then echo "SSH server did not respond after reboot" |