Skip to content

Commit

Permalink
#4 Add ci/cd with docker build/push
Browse files Browse the repository at this point in the history
  • Loading branch information
lbroudoux committed Jul 5, 2021
1 parent ea0fffa commit 54ced19
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
sudo: required

language: node_js
node_js: "14"

services:
- docker

after_success:
- if [ "$TRAVIS_BRANCH" == "master" ]; then
docker build -f Dockerfile -t quay.io/microcks/microcks-hub:latest .;
docker login -u "$QUAY_USERNAME" -p "$QUAY_PASSWORD" quay.io;
docker push quay.io/microcks/microcks-hub:latest;
fi
- if [ "$TRAVIS_BRANCH" == "$TRAVIS_TAG" ]; then
docker build -f Dockerfile -t quay.io/microcks/microcks-hub:$TRAVIS_TAG .;
docker login -u "$QUAY_USERNAME" -p "$QUAY_PASSWORD" quay.io;
docker push quay.io/microcks/microcks-hub:$TRAVIS_TAG;
fi

0 comments on commit 54ced19

Please sign in to comment.