From: David Taylor Date: Mon, 13 Dec 2021 22:57:16 +0000 (+0000) Subject: DEV: Pass `TAG` variable between workflow steps (#590) X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=3f8f4ce464345634962ea6f3efd11fc6a8042311;p=discourse_docker.git DEV: Pass `TAG` variable between workflow steps (#590) --- diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 15cbc19..d3ae5b4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,8 +31,10 @@ jobs: run: | docker run --rm -e RUBY_ONLY=1 -e USE_TURBO=1 -e SKIP_PLUGINS=1 -e SKIP_LINT=1 discourse/discourse_test:build - name: tag images + id: tag-images run: | TAG=`date +%Y%m%d-%H%M` + echo "::set-output name=tag::$(echo $TAG)" docker tag discourse/base:build discourse/base:2.0.$TAG-slim docker tag discourse/base:build discourse/base:slim docker tag discourse/base:build discourse/base:2.0.$TAG @@ -45,6 +47,7 @@ jobs: env: DOCKERHUB_PASSWORD: ${{ secrets.DOCKERHUB_PASSWORD }} run: | + TAG=${{ steps.tag-images.outputs.tag }} docker login --username discoursebuild --password $DOCKERHUB_PASSWORD docker push discourse/base:2.0.$TAG-slim docker push discourse/base:slim