Skip to content

Commit

Permalink
sleep more.
Browse files Browse the repository at this point in the history
  • Loading branch information
angerman committed Sep 9, 2023
1 parent 705c6d3 commit d78d9a9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .github/workflows/wait-and-upload.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ jobs:
steps:
- name: Get specific check run status
run: |
# start with a random sleep to prevent hitting the api too hard.
sleep $(($RANDOM % 180))
while [[ true ]]; do
# For GitHub Apps
# conclusion=$(gh api repos/$GITHUB_REPOSITORY/commits/$GITHUB_SHA/status --jq '.check_runs[] | select(.name == "ci/hydra-build:$DEV_SHELL") | .conclusion')
Expand All @@ -54,7 +56,7 @@ jobs:
*)
echo "conclusion is: '$conclusion'"
gh api repos/$GITHUB_REPOSITORY/commits/$GITHUB_SHA/status --paginate --jq '.'
WAIT=$((180 + $RANDOM % 60))
WAIT=$((180 + $RANDOM % 180))
echo "ci/hydra-build:$DEV_SHELL pending. Waiting ${WAIT}s..."
sleep $WAIT;;
esac
Expand Down

0 comments on commit d78d9a9

Please sign in to comment.