Skip to content

Commit

Permalink
CI: add timeout to version curl in Minecraft Pi (Modded)
Browse files Browse the repository at this point in the history
jenkins.thebrokenrail.com has horrible uptime and prolonged outages cause our updater CI to hang @TheBrokenRail
  • Loading branch information
theofficialgman committed Aug 26, 2023
1 parent a48f41c commit 90186e1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/updates/Minecraft Pi (Modded).sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@

# Build ID
# This obtains the latest successful build ID.
build_id="$(curl -s https://jenkins.thebrokenrail.com/job/minecraft-pi-reborn/job/master/lastStableBuild/buildNumber)"
build_id="$(curl -s --connect-timeout 15 https://jenkins.thebrokenrail.com/job/minecraft-pi-reborn/job/master/lastStableBuild/buildNumber)"

# Version Number
# This obtains the latest successful build's version number.
deb_id="$(curl -s "https://jenkins.thebrokenrail.com/job/minecraft-pi-reborn/job/master/${build_id}/api/json?tree=artifacts%5BrelativePath%5D" | jq | grep 'client-.*-arm64.AppImage"' | sed 's/.*client-//g' | sed 's/-arm64.*//g')"
deb_id="$(curl -s --connect-timeout 15 "https://jenkins.thebrokenrail.com/job/minecraft-pi-reborn/job/master/${build_id}/api/json?tree=artifacts%5BrelativePath%5D" | jq | grep 'client-.*-arm64.AppImage"' | sed 's/.*client-//g' | sed 's/-arm64.*//g')"

# Update
webVer="${build_id}/artifact/out/minecraft-pi-reborn-client-${deb_id}"
[ ! -z "$build_id" ] && [ ! -z "$deb_id" ] && webVer="${build_id}/artifact/out/minecraft-pi-reborn-client-${deb_id}"
# This URL is only used for validation.
armhf_url="https://jenkins.thebrokenrail.com/job/minecraft-pi-reborn/job/master/${webVer}-armhf.AppImage"
arm64_url="https://jenkins.thebrokenrail.com/job/minecraft-pi-reborn/job/master/${webVer}-arm64.AppImage"
Expand Down

0 comments on commit 90186e1

Please sign in to comment.