Skip to content

Commit

Permalink
Add publish stage to travis
Browse files Browse the repository at this point in the history
  • Loading branch information
phlax committed Apr 11, 2018
1 parent 59daf3c commit 7f1ddc5
Showing 1 changed file with 24 additions and 2 deletions.
26 changes: 24 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ env:
global:
# for this to work you also need to comment out build condition
# as travis' conditions are currently broken
- FORCE_REBUILD=false
- FORCE_REBUILD=true

cache:
directories:
Expand All @@ -19,14 +19,22 @@ cache:
- $HOME/virtualenv/python2.7.14/lib
- $HOME/virtualenv/python2.7/bin

stages:
- name: build
if: branch = master AND type = push
- name: test
if: branch = DOESNOTEXIST
- name: publish
# if: branch = master AND type = push
- name: data

install:
- pip install -qr requirements/host.txt

jobs:
include:
- stage: build
env: POOTLE_ENV=build
if: branch = master AND type = push
script:
- export DOCKER_USERNAME=${DOCKER_USERNAME:-translatetravis2}
- makey build-travis-images
Expand Down Expand Up @@ -61,6 +69,20 @@ jobs:
- docker-compose pull --parallel --include-deps dev-travis-mariadb
- makey makey-mariadb-travis travis-test

- stage: publish
env: POOTLE_ENV=publish-demo
script:
- export LOCAL_USER_ID=$UID
- export DOCKER_USERNAME=${DOCKER_USERNAME:-translatetravis2}
- export DOCKER_PUBLISH_NAME=${DOCKER_PUBLISH_NAME:-translate}
- makey publish-demo-images
- stage: data
env: POOTLE_ENV=publish-demo-db
script:
- export LOCAL_USER_ID=$UID
- export DOCKER_USERNAME=${DOCKER_USERNAME:-translatetravis2}
- makey publish-demo-db

notifications:
email:
on_failure: always
Expand Down

0 comments on commit 7f1ddc5

Please sign in to comment.