Skip to content

Commit

Permalink
feat(ci): retry upload installer (#2286)
Browse files Browse the repository at this point in the history
  • Loading branch information
Leo Ryu committed May 14, 2023
1 parent a68e8de commit 3c580f6
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions build/docker/tools/tke-installer/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,19 @@ function build::installer() {

echo "current builder is ${BUILDER}"
if [[ "${BUILDER}" == "tke" ]]; then
echo "start upload process"
coscmd upload "${INSTALLER_DIR}/$installer" "$installer"
coscmd upload "$OUTPUT_DIR/$installer.sha256" "$installer.sha256"
echo "start upload"
max_tries=3
for i in $(seq 1 $max_tries); do
coscmd upload "${INSTALLER_DIR}/$installer" "$installer" && coscmd upload "$OUTPUT_DIR/$installer.sha256" "$installer.sha256"
result=$?
if [[ $result -eq 0 ]]; then
echo "upload successful"
break
else
echo "upload failed"
sleep 1
fi
done
fi
}

Expand Down

0 comments on commit 3c580f6

Please sign in to comment.