-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy path.travis.yml
32 lines (30 loc) · 1010 Bytes
/
.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
language: ruby
sudo: false
cache: bundler
before_install:
- pyenv global 3.7.1
- pip install -U pip
- pip install awscli
install:
- gem install bundler --version '1.17.3'
after_success:
- docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD"
- export REPO=gabriprat/hoshinplan
- export TAG=`if [ "$TRAVIS_BRANCH" == "master" ]; then echo "latest"; else echo $TRAVIS_BRANCH ; fi`
- export COMMIT=$TRAVIS_COMMIT
- docker build -f Dockerfile -t $REPO:$COMMIT -t $REPO:$TAG -t $REPO:travis-$TRAVIS_BUILD_NUMBER .
- docker push $REPO --all-tags
- ./bin/bump-task.sh travis-$TRAVIS_BUILD_NUMBER hoshinplan web
- ./bin/bump-task.sh travis-$TRAVIS_BUILD_NUMBER hoshinplan-worker workers
- ./bin/bump-task.sh travis-$TRAVIS_BUILD_NUMBER hoshinplan-clock clock
addons:
postgresql: "9.4"
before_script:
- psql -c 'create database travis_ci_test;' -U postgres
- bundle install --deployment
- bundle exec rake db:test:prepare
services:
- docker
- redis-server
rvm:
- ruby-2.5.7