Skip to content

[ci] Retry installing gradle/wrapper up to 5 times #105787

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .ci/scripts/packaging-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ BUILD_JAVA_HOME=$HOME/.java/$ES_BUILD_JAVA
rm -Rfv $HOME/.gradle/init.d/ && mkdir -p $HOME/.gradle/init.d
cp -v .ci/init.gradle $HOME/.gradle/init.d

for attempt in 1 2 3 4 5; do ./gradlew --version && break; echo "Failed to download gradle wrapper - attempt $attempt/5" && sleep 5; done

unset JAVA_HOME

if [ -f "/etc/os-release" ] ; then
Expand Down
1 change: 1 addition & 0 deletions .ci/scripts/run-gradle.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,5 @@ else
fi

set -e
for attempt in 1 2 3 4 5; do ./gradlew --version && break; echo "Failed to download gradle wrapper - attempt $attempt/5" && sleep 5; done
$GRADLEW -S --max-workers=$MAX_WORKERS $@