Fix travis build

Signed-off-by: Christoph <auer.chrisi@gmx.net>
This commit is contained in:
Christoph 2016-04-01 20:29:08 +02:00
parent 2826bb9134
commit 6bac9029fa
1 changed files with 3 additions and 2 deletions

View File

@ -50,10 +50,11 @@ setup_chroot() {
if [ ! -f $archive ]; then
# get root fs
local curl=$(curl --fail -O "$ARCH_TRAVIS_MIRROR/iso/$ARCH_TRAVIS_ARCH_ISO/$archive" 2>&1)
curl --fail -O "$ARCH_TRAVIS_MIRROR/iso/$ARCH_TRAVIS_ARCH_ISO/$archive" 2>&1
local ret=$?
# if it fails, try arch iso form the previous month
if [ $? -gt 0 ]; then
if [ $ret -gt 0 ]; then
ARCH_TRAVIS_ARCH_ISO="$(date +%Y.%m -d "-1 month").01"
archive="archlinux-bootstrap-$ARCH_TRAVIS_ARCH_ISO-x86_64.tar.gz"
as_normal "curl -O $ARCH_TRAVIS_MIRROR/iso/$ARCH_TRAVIS_ARCH_ISO/$archive"