Skip to content

Commit

Permalink
Fix image build on tags (#11271)
Browse files Browse the repository at this point in the history
  • Loading branch information
sampaiodiego authored and rodrigok committed Jun 27, 2018
1 parent 92526f5 commit c06a730
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -291,16 +291,16 @@ jobs:
echo "Build preview Docker image"
cp ~/repo/.docker-mongo/Dockerfile .
cp ~/repo/.docker-mongo/entrypoint.sh .
docker build -t rocketchat/rocket.chat-preview:$CIRCLE_TAG .
docker push rocketchat/rocket.chat-preview:$CIRCLE_TAG
docker build -t rocketchat/rocket.chat.preview:$CIRCLE_TAG .
docker push rocketchat/rocket.chat.preview:$CIRCLE_TAG
if [[ $CIRCLE_TAG =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
if echo "$CIRCLE_TAG" | grep -Eq '^[0-9]+\.[0-9]+\.[0-9]+$' ; then
docker tag rocketchat/rocket.chat:$CIRCLE_TAG rocketchat/rocket.chat:latest
docker push rocketchat/rocket.chat:latest
docker tag rocketchat/rocket.chat.preview:$CIRCLE_TAG rocketchat/rocket.chat.preview:latest
docker push rocketchat/rocket.chat.preview:latest
else
elif echo "$CIRCLE_TAG" | grep -Eq '^[0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+$' ; then
docker tag rocketchat/rocket.chat:$CIRCLE_TAG rocketchat/rocket.chat:release-candidate
docker push rocketchat/rocket.chat:release-candidate
Expand Down

0 comments on commit c06a730

Please sign in to comment.