Skip to content

Commit

Permalink
Merge pull request ethereum#109 from tomochain/hotfix/travisstash
Browse files Browse the repository at this point in the history
Hotfix broken travis deployment
  • Loading branch information
ngtuna authored Jul 31, 2018
2 parents b1c8d65 + 3d894ed commit 89df8f1
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 33 deletions.
56 changes: 29 additions & 27 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
sudo: required
language: go
go_import_path: github.com/ethereum/go-ethereum
services: skip

jobs:
include:
Expand Down Expand Up @@ -54,44 +53,47 @@ jobs:
branch: master
tags: true

- stage: Build and push tomochain/tomochain image
- stage: Build and push untagged commit into image tomochain
services:
- docker
before_install:
install: skip
before_script:
- docker build -t tomochain/tomochain .
- docker run tomochain/tomochain
install: skip
script: skip
deploy:
- provider: script
script:
- bash docker_push.sh latest
- bash docker_push.sh $TRAVIS_BUILD_ID
on:
branch: master
tags: false
- provider: script
script:
- bash docker_push.sh latest
- bash docker_push.sh $TRAVIS_TAG
on:
branch: master
tags: true
script:
- echo "$DOCKER_PASSWORD" | docker login --username "$DOCKER_USERNAME" --password-stdin
- docker tag tomochain/tomochain tomochain/tomochain:latest
- docker push tomochain/tomochain:latest
- docker tag tomochain/tomochain tomochain/tomochain:$TRAVIS_BUILD_ID
- docker push tomochain/tomochain:$TRAVIS_BUILD_ID
after_success:
- curl -X POST $INFRA_IMAGE_REBUILD_HOOK

- stage: Trigger rebuild of tomochain/infra-tomochain image
sudo: false
- stage: Build and push tagged commit into image tomochain
services:
- docker
install: skip
script: bash docker_rebuild.sh
before_script:
- docker build -t tomochain/tomochain .
- docker run tomochain/tomochain
script:
- echo "$DOCKER_PASSWORD" | docker login --username "$DOCKER_USERNAME" --password-stdin
- docker tag tomochain/tomochain tomochain/tomochain:latest
- docker push tomochain/tomochain:latest
- docker tag tomochain/tomochain tomochain/tomochain:$TRAVIS_TAG
- docker push tomochain/tomochain:$TRAVIS_TAG
after_success:
- curl -X POST $INFRA_IMAGE_REBUILD_HOOK

stages:
- name: Lint
- name: Build and test
- name: Github release
if: type != pull_request AND branch = master AND tag = true AND repo = tomochain/tomochain
- name: Build and push tomochain/tomochain image
if: type != pull_request AND branch = master AND repo = tomochain/tomochain
- name: Trigger rebuild of tomochain/infra-tomochain image
if: type != pull_request AND branch = master AND repo = tomochain/tomochain
- name: Build and push untagged commit into image tomochain
if: type != pull_request AND branch = master AND tag = false AND repo = tomochain/tomochain
- name: Build and push tagged commit into image tomochain
if: type != pull_request AND branch = master AND tag = true AND repo = tomochain/tomochain

notifications:
slack:
Expand Down
5 changes: 0 additions & 5 deletions docker_push.sh

This file was deleted.

1 change: 0 additions & 1 deletion docker_rebuild.sh

This file was deleted.

0 comments on commit 89df8f1

Please sign in to comment.