language: go
sudo: required
dist: trusty
go: "1.12"

services:
- docker

install: true
script:
  - make check

deploy:
- provider: script
  script: docker login -u="$DOCKER_USER" -p="$DOCKER_PASS" quay.io && make container docker-push
  skip_cleanup: true
  on:
    branch: master
- provider: script
  script: docker login -u="$DOCKER_USER" -p="$DOCKER_PASS" quay.io && make container docker-push IMAGE_TAG=$TRAVIS_TAG
  skip_cleanup: true
  on:
    tags: true
