language: go
go:
  - 1.5.1
env:
  - GO15VENDOREXPERIMENT=1
branches:
  only:
    - master
cache:
  directories:
    - $HOME/.cache/pip
    - $GOPATH/src/github.com/deis/workflow/vendor
    - $HOME/venv
services:
  - docker
  - postgresql
sudo: required
addons:
  postgresql: "9.3"
before_install:
  - wget "https://github.com/Masterminds/glide/releases/download/0.7.2/glide-0.7.2-linux-amd64.tar.gz"
  - sudo tar -vxz -C /usr/local/bin --strip=1 -f glide-0.7.2-linux-amd64.tar.gz
  - go get github.com/golang/lint/golint
  - wget "http://ftp.debian.org/debian/pool/main/s/shellcheck/shellcheck_0.3.7-5_amd64.deb"
  - sudo dpkg -i shellcheck_0.3.7-5_amd64.deb
  - sudo pip install virtualenv
  - virtualenv $HOME/venv
  - source $HOME/venv/bin/activate
  - createdb -U postgres deis
install:
  - pip install -r rootfs/requirements.txt
  - pip install -r rootfs/dev_requirements.txt
  - make -C docs/ deps
  - GLIDE_HOME=/home/travis/.glide make -C client bootstrap
script:
  - make test
  - make -C client/ test
  - make -C docs/ test
deploy:
  provider: script
  script: _scripts/deploy.sh
  on:
    branch: master
