mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
c460728225
* build: increase saucelabs connect timeout At some point we went down from a 2min wait timeout to 30seconds because we re-ran the startup script if something failed. Since re-running didn't really help and we removed it, we should move the timeout back to a longer period. e.g. see: https://circleci.com/gh/angular/material2/25254 where it successfully acquired a tunnel, but just didn't have enough time to actually establish it. * Switch to rewritten saucelabs version * Update to latest saucelabs launcher version
29 lines
723 B
Bash
Executable File
29 lines
723 B
Bash
Executable File
#!/bin/bash
|
|
|
|
tunnelTmpDir="/tmp/material-saucelabs"
|
|
tunnelReadyFile="${tunnelTmpDir}/readyfile"
|
|
|
|
WAIT_DELAY=120
|
|
|
|
# Wait for Saucelabs Connect to be ready before exiting
|
|
# Time out if we wait for more than 2 minutes, so the process won't run forever.
|
|
let "counter=0"
|
|
|
|
while [ ! -f ${tunnelReadyFile} ]; do
|
|
let "counter++"
|
|
|
|
# Counter needs to be multiplied by two because the while loop only sleeps a half second.
|
|
# This has been made in favor of better progress logging (printing dots every half second)
|
|
if [ $counter -gt $[${WAIT_DELAY} * 2] ]; then
|
|
echo ""
|
|
echo "Timed out after 2 minutes waiting for tunnel ready file"
|
|
exit 5
|
|
fi
|
|
|
|
printf "."
|
|
sleep 0.5
|
|
done
|
|
|
|
echo ""
|
|
echo "Connected to Saucelabs"
|