Skip to content

Commit

Permalink
change retry
Browse files Browse the repository at this point in the history
  • Loading branch information
youyuanwu committed Nov 20, 2023
1 parent 7d239ca commit c6abee5
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -98,13 +98,13 @@ jobs:

- name: test cluster health
run: |
max_retry=10
counter=0
until sfctl cluster select; do
COMMAND_STATUS=1
until [ $COMMAND_STATUS -eq 0 || $counter -eq 10 ]; do
sfctl cluster select
COMMAND_STATUS=$?
sleep 1
[[ counter -eq $max_retry ]] && echo "Failed!" && cat /home/sfuser/sfdevcluster/data/log/* && exit 1
echo "Trying again. Try #$counter"
((counter++))
let counter=counter+1
done
sfctl cluster health
Expand Down

0 comments on commit c6abee5

Please sign in to comment.