
language: ruby
sudo: false
cache: bundler

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 .
  - docker tag $REPO:$COMMIT $REPO:$TAG
  - docker tag $REPO:$COMMIT $REPO:travis-$TRAVIS_BUILD_NUMBER
  - docker push $REPO
addons:
  postgresql: "9.4"
before_script:
  - psql -c 'create database travis_ci_test;' -U postgres
  - bundle exec rake db:test:prepare
services:
  - docker
  - redis
rvm:
  - ruby-2.4.1


language: ruby
sudo: false
cache: bundler

install:
  - gem uninstall bundler
  - gem install bundler --version '1.16.0'
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 .
  - docker tag $REPO:$COMMIT $REPO:$TAG
  - docker tag $REPO:$COMMIT $REPO:travis-$TRAVIS_BUILD_NUMBER
  - docker push $REPO
addons:
  postgresql: "9.4"
before_script:
  - psql -c 'create database travis_ci_test;' -U postgres
  - bundle exec rake db:test:prepare
services:
  - docker
  - redis
rvm:
  - ruby-2.4.1

Fix build error: Can't find bundler
Fix build error: Can't find bundler
