summaryrefslogtreecommitdiff
path: root/platform/linux/scripts/after_script.sh
diff options
context:
space:
mode:
Diffstat (limited to 'platform/linux/scripts/after_script.sh')
-rwxr-xr-xplatform/linux/scripts/after_script.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/platform/linux/scripts/after_script.sh b/platform/linux/scripts/after_script.sh
new file mode 100755
index 0000000000..f8e4bc3486
--- /dev/null
+++ b/platform/linux/scripts/after_script.sh
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+set -e
+set -o pipefail
+
+if [ ! -z "${AWS_ACCESS_KEY_ID}" ] && [ ! -z "${AWS_SECRET_ACCESS_KEY}" ] ; then
+ # Install and add awscli to PATH for uploading the results
+ pip install --user awscli
+ export PATH="`python -m site --user-base`/bin:${PATH}"
+
+ REPO_NAME=$(basename $TRAVIS_REPO_SLUG)
+
+ aws s3 cp --recursive --acl public-read test/fixtures/annotations \
+ s3://mapbox/$REPO_NAME/render-tests/$TRAVIS_JOB_NUMBER/annotations
+fi