Skip to content

Commit

Permalink
check axel tarball file integrity
Browse files Browse the repository at this point in the history
redownload from local centminmod.com mirror if github axel download is invalid
  • Loading branch information
centminmod committed Jun 21, 2016
1 parent e38ea78 commit 8707ddd
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions inc/axelsetup.inc
Expand Up @@ -65,6 +65,12 @@ else
fi
fi

if [[ "$(tar -tzf axel-${AXEL_VER}.tar.gz >/dev/null; echo $?)" != '0' ]]; then
rm -rf /svr-setup/axel-${AXEL_VER}.*
echo "re-try download form local mirror..."
wget -O $AXEK_LINKFILE $AXEK_LINKLOCAL
fi

tar xzf $AXEK_LINKFILE
ERROR=$?
if [[ "$ERROR" != '0' ]]; then
Expand Down

0 comments on commit 8707ddd

Please sign in to comment.