Push demo artifact to docker hub

This commit is contained in:
Alex Peters
2020-01-22 17:19:49 +01:00
parent 076711ac2b
commit e99bf56cb5

View File

@@ -195,21 +195,19 @@ jobs:
at: /tmp/workspace at: /tmp/workspace
- checkout - checkout
- setup_remote_docker: - setup_remote_docker:
docker_layer_caching: true docker_layer_caching: yes
- run: | - run:
GAIAD_VERSION='' name: Build Docker artifact - demo
if [ "${CIRCLE_BRANCH}" = "master" ]; then command: docker build --pull -t "cosmwasm/wasmd-demo:${CIRCLE_SHA1}" .
GAIAD_VERSION="stable" - run:
elif [ "${CIRCLE_BRANCH}" = "develop" ]; then name: Push application Docker image to docker hub
GAIAD_VERSION="develop" command: |
fi if [ "${CIRCLE_BRANCH}" = "master" ]; then
if [ -z "${GAIAD_VERSION}" ]; then docker tag "cosmwasm/wasmd-demo:${CIRCLE_SHA1}" cosmwasm/wasmd-demo:latest
docker build . docker login --password-stdin -u "$DOCKER_USER" \<<<"$DOCKER_PASS"
else docker push cosmwasm/wasmd-demo:latest
docker build -t cosmwasm/wasmd:$GAIAD_VERSION . docker logout
docker login --password-stdin -u $DOCKER_USER \<<<$DOCKER_PASS fi
docker push cosmwasm/wasmd:$GAIAD_VERSION
fi
docker-tagged: docker-tagged:
executor: golang executor: golang
@@ -218,11 +216,16 @@ jobs:
at: /tmp/workspace at: /tmp/workspace
- checkout - checkout
- setup_remote_docker: - setup_remote_docker:
docker_layer_caching: true docker_layer_caching: yes
- run: | - run:
docker build -t tendermint/gaia:$CIRCLE_TAG . name: Build Docker artifact - demo
docker login --password-stdin -u $DOCKER_USER \<<$DOCKER_PASS command: docker build --pull -t "cosmwasm/wasmd-demo:${CIRCLE_TAG}" . .
docker push tendermint/gaia:$CIRCLE_TAG - run:
name: Push application Docker image to docker hub
command: |
docker login --password-stdin -u "$DOCKER_USER" \<<<"$DOCKER_PASS"
docker push "cosmwasm/wasmd-demo:${CIRCLE_TAG}"
docker logout
reproducible-builds: reproducible-builds:
executor: golang executor: golang
@@ -274,19 +277,19 @@ workflows:
version: 2 version: 2
test-suite: test-suite:
jobs: jobs:
# - docker-image: - docker-image:
# requires: requires:
# - setup-dependencies - setup-dependencies
# - docker-tagged: - docker-tagged:
# filters: filters:
# tags: tags:
# only: only:
# - /^v.*/ - /^v.*/
# branches: branches:
# ignore: ignore:
# - /.*/ - /.*/
# requires: requires:
# - setup-dependencies - setup-dependencies
- setup-dependencies: - setup-dependencies:
# filters here are needed to enable this job also for tags # filters here are needed to enable this job also for tags
filters: filters: