forked from alephdata/aleph
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
48 lines (42 loc) · 1.37 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
sudo: required
services:
- docker
env:
global:
- DOCKER_COMPOSE_VERSION=1.23.2
before_install:
- sudo apt-get update
- sudo apt-get -y -o Dpkg::Options::="--force-confnew" install docker-ce
- sudo sysctl -w vm.max_map_count=262144
- sudo rm /usr/local/bin/docker-compose
- curl -L https://github.com/docker/compose/releases/download/${DOCKER_COMPOSE_VERSION}/docker-compose-`uname -s`-`uname -m` > docker-compose
- chmod +x docker-compose
- sudo mv docker-compose /usr/local/bin
- sudo echo "ALEPH_SECRET=batman\n" >> aleph.env
- docker --version
- docker-compose --version
- make docker-pull
install:
- echo "${TRAVIS_BRANCH}"
- make build
- make services
- sleep 5
script:
- make ingest-test
- make test
after_success:
- echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
- make ALEPH_TAG=$TRAVIS_COMMIT build-full docker-push
- if [[ $TRAVIS_BRANCH = "master" ]]; then
make ALEPH_TAG=master build-full docker-push ;
fi
- if [[ $TRAVIS_BRANCH = "develop" ]]; then
make ALEPH_TAG=develop build-full docker-push ;
fi
- if [[ $TRAVIS_BRANCH = "occrp/production" ]]; then
make ALEPH_TAG=occrp build-full docker-push ;
fi
- if [[ $TRAVIS_TAG = $TRAVIS_BRANCH ]]; then
make ALEPH_TAG=$TRAVIS_TAG build-full docker-push ;
make ALEPH_TAG=latest build-full docker-push ;
fi