Skip to content
Snippets Groups Projects
Commit bab7af9f authored by rhenck's avatar rhenck
Browse files

Make travis always build docker image with latest tag

The tagged image will be produced on tagged git commits as well.
parent 55b2ba59
No related branches found
No related tags found
No related merge requests found
...@@ -16,8 +16,10 @@ after_script: ...@@ -16,8 +16,10 @@ after_script:
- make stop - make stop
after_success: after_success:
- if [ "$TRAVIS_TAG" ]; then - echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin;
echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin; docker build -t iqbberlin/testcenter-frontend:latest -f docker/Dockerfile .;
docker build --target prod -t iqbberlin/testcenter-frontend:$TRAVIS_TAG -f docker/Dockerfile .; docker push iqbberlin/testcenter-frontend:latest;
if [ "$TRAVIS_TAG" ]; then
docker tag iqbberlin/testcenter-frontend:latest iqbberlin/testcenter-frontend:$TRAVIS_TAG;
docker push iqbberlin/testcenter-frontend:$TRAVIS_TAG; docker push iqbberlin/testcenter-frontend:$TRAVIS_TAG;
fi fi
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment