2018-10-05 10:51:35 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
2019-01-24 15:23:25 +02:00
|
|
|
# Skip deploy for staging branch
|
|
|
|
[ "$TRAVIS_BRANCH" = "staging" ] && exit 0
|
|
|
|
|
|
|
|
# Retag in case of `bors try`
|
|
|
|
if [ "$TRAVIS_BRANCH" = "testing" ]; then
|
2019-01-22 16:39:42 +02:00
|
|
|
export DOCKER_ORG="mailutest"
|
2019-01-24 15:23:25 +02:00
|
|
|
# Commit message is like "Try #99".
|
|
|
|
# This sets the version tag to "pr-99"
|
|
|
|
export MAILU_VERSION="pr-${TRAVIS_COMMIT_MESSAGE//[!0-9]/}"
|
2019-01-22 16:39:42 +02:00
|
|
|
docker-compose -f tests/build.yml build
|
|
|
|
fi
|
|
|
|
|
2019-01-24 15:23:25 +02:00
|
|
|
docker login -u $DOCKER_UN -p $DOCKER_PW
|
|
|
|
docker-compose -f tests/build.yml push
|