diff --git a/deploy/ci/travis/e2e-build-script.sh b/deploy/ci/travis/e2e-build-script.sh index 48f58af62f..757bd7dd42 100755 --- a/deploy/ci/travis/e2e-build-script.sh +++ b/deploy/ci/travis/e2e-build-script.sh @@ -50,6 +50,7 @@ function tryGetExistingBuild() { fi } +# Need S3 endpoint - if we don't have it, we don't have the Travis env vars if [ -n "${AWS_ENDPOINT}" ]; then tryGetExistingBuild fi @@ -68,14 +69,16 @@ else npm run build npm run build-backend - set +e - tar cvfz ${GZIP_NAME} dist/* src/jetstream/jetstream + # Only try to upload if we have the S3 configuration + if [ -n "${AWS_ENDPOINT}" ]; then + set +e + tar cvfz ${GZIP_NAME} dist/* src/jetstream/jetstream - # Upload - mc cp -q --insecure ${GZIP_NAME} ${MC_HOST}/${S3_BUILDS_BUCKET} - - # Ignore error from uploading - should not fail build if we can't upload the build archive - # This just means we won't be able to us this cache next build - exit 0 + # Upload + mc cp -q --insecure ${GZIP_NAME} ${MC_HOST}/${S3_BUILDS_BUCKET} + # Ignore error from uploading - should not fail build if we can't upload the build archive + # This just means we won't be able to us this cache next build + echo "Uploaded builds" + fi fi diff --git a/deploy/ci/travis/e2e-mc-helper.sh b/deploy/ci/travis/e2e-mc-helper.sh index 4dbb3109b6..5201e0a46f 100644 --- a/deploy/ci/travis/e2e-mc-helper.sh +++ b/deploy/ci/travis/e2e-mc-helper.sh @@ -1,6 +1,7 @@ # Helper for mc command -mc version > /dev/null +# Check if mc command is available (don't log error if it is not) +mc version > /dev/null 2>&1 if [ $? -eq 0 ]; then echo "mc command already installed and confgiured" else