chore: push "latest" image on dockerhub
@@ -163,6 +163,12 @@ jobs:
--build-arg GRAVITEEIO_VERSION=${APIM_VERSION} \
-t ${IMAGE_TAG} .
+ if [[ $CIRCLE_BRANCH =~ ^([0-9]+\.[0-9]+\.x|master)$ ]]
+ then
+ docker login --username="${DOCKERHUB_BOT_USER_NAME}" -p="${DOCKERHUB_BOT_USER_TOKEN}"
+ docker push ${IMAGE_TAG}
+ fi
+
echo $AZURE_DOCKER_REGISTRY_PASSWORD | docker login --username $AZURE_DOCKER_REGISTRY_USERNAME --password-stdin graviteeio.azurecr.io
docker push ${IMAGE_TAG}
- persist_to_workspace:
@@ -278,6 +284,12 @@ workflows:
- secrethub/env-export:
secret-path: graviteeio/cicd/azure/docker-registries/graviteeio/password
var-name: AZURE_DOCKER_REGISTRY_PASSWORD
+ - secrethub/env-export:
+ secret-path: graviteeio/cicd/graviteebot/infra/dockerhub-user-name
+ var-name: DOCKERHUB_BOT_USER_NAME
+ - secrethub/env-export:
+ secret-path: graviteeio/cicd/graviteebot/infra/dockerhub-user-token
+ var-name: DOCKERHUB_BOT_USER_TOKEN
filters:
branches:
only:
