From fe967dcf466b06b50ebbce42b7299a3849e17c9d Mon Sep 17 00:00:00 2001 From: Bryan Paget Date: Wed, 26 Jul 2023 13:57:12 -0400 Subject: [PATCH 1/9] Update build_push.yaml: deprecate set-output update workflow to use $GITHUB_OUTPUT instead of set-output. See: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/ --- .github/workflows/build_push.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_push.yaml b/.github/workflows/build_push.yaml index 0369ed23a..b22b54548 100644 --- a/.github/workflows/build_push.yaml +++ b/.github/workflows/build_push.yaml @@ -110,7 +110,7 @@ jobs: id: notebook-name shell: bash run: | - echo ::set-output name=NOTEBOOK_NAME::${{ matrix.notebook }} + echo "${{ NOTEBOOK_NAME }}=${{ matrix.notebook }}" >> $GITHUB_OUTPUT # Connect to Azure Container registry (ACR) - uses: azure/docker-login@v1 @@ -183,7 +183,7 @@ jobs: github.event_name == 'pull_request' && contains( github.event.pull_request.labels.*.name, 'auto-deploy') ) - run: echo "::set-output name=boolean::true" + run: echo 'boolean=true' >> $GITHUB_OUTPUT # Pull the local image back, then "build" it (will just tag the pulled image) - name: Pull image back from local repo From c7b839b4dda062a80d830ecd1a21c3365c0eb1a2 Mon Sep 17 00:00:00 2001 From: Bryan Paget Date: Wed, 26 Jul 2023 13:59:09 -0400 Subject: [PATCH 2/9] Update build_push.yaml: update syntax --- .github/workflows/build_push.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_push.yaml b/.github/workflows/build_push.yaml index b22b54548..e666cf4c9 100644 --- a/.github/workflows/build_push.yaml +++ b/.github/workflows/build_push.yaml @@ -110,7 +110,7 @@ jobs: id: notebook-name shell: bash run: | - echo "${{ NOTEBOOK_NAME }}=${{ matrix.notebook }}" >> $GITHUB_OUTPUT + echo "{NOTEBOOK_NAME}={matrix.notebook}" >> $GITHUB_OUTPUT # Connect to Azure Container registry (ACR) - uses: azure/docker-login@v1 From 17e813696f7dc8e81fd06c132b7a2092131d801f Mon Sep 17 00:00:00 2001 From: Bryan Paget Date: Thu, 27 Jul 2023 10:09:48 -0400 Subject: [PATCH 3/9] Update build_push.yaml: update syntax for interpolation --- .github/workflows/build_push.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_push.yaml b/.github/workflows/build_push.yaml index e666cf4c9..6f42d1976 100644 --- a/.github/workflows/build_push.yaml +++ b/.github/workflows/build_push.yaml @@ -110,7 +110,7 @@ jobs: id: notebook-name shell: bash run: | - echo "{NOTEBOOK_NAME}={matrix.notebook}" >> $GITHUB_OUTPUT + echo "${{ steps.notebook-name.outputs.NOTEBOOK_NAME }}=${{ matrix.notebook }}" >> $GITHUB_OUTPUT # Connect to Azure Container registry (ACR) - uses: azure/docker-login@v1 From 578c0e22deb838be7e37fc49859d6b386ef77e37 Mon Sep 17 00:00:00 2001 From: Bryan Paget Date: Thu, 27 Jul 2023 10:21:48 -0400 Subject: [PATCH 4/9] Update build_push.yaml: change notebook name variable name --- .github/workflows/build_push.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_push.yaml b/.github/workflows/build_push.yaml index 6f42d1976..b22b54548 100644 --- a/.github/workflows/build_push.yaml +++ b/.github/workflows/build_push.yaml @@ -110,7 +110,7 @@ jobs: id: notebook-name shell: bash run: | - echo "${{ steps.notebook-name.outputs.NOTEBOOK_NAME }}=${{ matrix.notebook }}" >> $GITHUB_OUTPUT + echo "${{ NOTEBOOK_NAME }}=${{ matrix.notebook }}" >> $GITHUB_OUTPUT # Connect to Azure Container registry (ACR) - uses: azure/docker-login@v1 From 69f92bd9e27798fd16374be40adabb84013aae4c Mon Sep 17 00:00:00 2001 From: Bryan Paget Date: Thu, 27 Jul 2023 10:28:55 -0400 Subject: [PATCH 5/9] Update build_push.yaml: update syntax --- .github/workflows/build_push.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_push.yaml b/.github/workflows/build_push.yaml index b22b54548..c4f3d82a6 100644 --- a/.github/workflows/build_push.yaml +++ b/.github/workflows/build_push.yaml @@ -110,7 +110,7 @@ jobs: id: notebook-name shell: bash run: | - echo "${{ NOTEBOOK_NAME }}=${{ matrix.notebook }}" >> $GITHUB_OUTPUT + echo ${{ steps.notebook-name.outputs.NOTEBOOK_NAME }}=${{ matrix.notebook }} >> $GITHUB_OUTPUT # Connect to Azure Container registry (ACR) - uses: azure/docker-login@v1 From e03f255357829f132c8eff86dab17c2f72811da9 Mon Sep 17 00:00:00 2001 From: Bryan Paget Date: Thu, 27 Jul 2023 10:37:01 -0400 Subject: [PATCH 6/9] Update build_push.yaml: update syntax --- .github/workflows/build_push.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_push.yaml b/.github/workflows/build_push.yaml index c4f3d82a6..8c07f6ceb 100644 --- a/.github/workflows/build_push.yaml +++ b/.github/workflows/build_push.yaml @@ -110,7 +110,7 @@ jobs: id: notebook-name shell: bash run: | - echo ${{ steps.notebook-name.outputs.NOTEBOOK_NAME }}=${{ matrix.notebook }} >> $GITHUB_OUTPUT + echo ${{ env.NOTEBOOK_NAME }}=${{ matrix.notebook }} >> $GITHUB_OUTPUT # Connect to Azure Container registry (ACR) - uses: azure/docker-login@v1 From 6e1add98a0538c3b2ae69dc3350de1d1e4f8cd6f Mon Sep 17 00:00:00 2001 From: Bryan Paget Date: Thu, 27 Jul 2023 10:37:54 -0400 Subject: [PATCH 7/9] Update build_push.yaml: update syntax --- .github/workflows/build_push.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_push.yaml b/.github/workflows/build_push.yaml index 8c07f6ceb..020123100 100644 --- a/.github/workflows/build_push.yaml +++ b/.github/workflows/build_push.yaml @@ -110,7 +110,7 @@ jobs: id: notebook-name shell: bash run: | - echo ${{ env.NOTEBOOK_NAME }}=${{ matrix.notebook }} >> $GITHUB_OUTPUT + echo NOTEBOOK_NAME=${{ matrix.notebook }} >> $GITHUB_OUTPUT # Connect to Azure Container registry (ACR) - uses: azure/docker-login@v1 From 771dd524615b949dac5be42752bc14b7ad1e9614 Mon Sep 17 00:00:00 2001 From: Bryan Paget Date: Thu, 27 Jul 2023 16:51:56 +0000 Subject: [PATCH 8/9] update remaining set-output commands --- Makefile | 6 +++--- make_helpers/get_branch_name.sh | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 7bb078476..2a6249f18 100644 --- a/Makefile +++ b/Makefile @@ -198,9 +198,9 @@ build/%: ## build the latest image docker build $(DARGS) --rm --force-rm -t $$IMAGE_NAME ./output/$(notdir $@) && \ echo -n "Built image $$IMAGE_NAME of size: " && \ docker images $$IMAGE_NAME --format "{{.Size}}" && \ - echo "::set-output name=full_image_name::$$IMAGE_NAME" && \ - echo "::set-output name=image_tag::$(TAG)" && \ - echo "::set-output name=image_repo::$${REPO}" + echo full_image_name=$$IMAGE_NAME >> $GITHUB_OUTPUT && \ + echo image_tag=$(TAG) && \ + echo image_repo=$${REPO} post-build/%: export REPO?=$(DEFAULT_REPO) post-build/%: export TAG?=$(DEFAULT_TAG) diff --git a/make_helpers/get_branch_name.sh b/make_helpers/get_branch_name.sh index 42cfb47a5..6ecd9aac8 100755 --- a/make_helpers/get_branch_name.sh +++ b/make_helpers/get_branch_name.sh @@ -21,7 +21,6 @@ if [[ $GITHUB_ACTIONS == "true" ]] ; then BRANCH_NAME="" fi - # echo "::set-output name=branch_name::$BRANCH_NAME" else BRANCH_NAME=`git rev-parse --abbrev-ref HEAD` fi From 8dfd920d0e3b85fcf73a1f2cbe9824c8233e8ae7 Mon Sep 17 00:00:00 2001 From: Bryan Paget Date: Thu, 27 Jul 2023 15:41:45 -0400 Subject: [PATCH 9/9] Update Makefile: reset set-output commands for Makefile Github Actions was complaining about set-output in the Makefile but I think we have to leave these lines alone since they are used by Make and not by Github Actions. --- Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 2a6249f18..7bb078476 100644 --- a/Makefile +++ b/Makefile @@ -198,9 +198,9 @@ build/%: ## build the latest image docker build $(DARGS) --rm --force-rm -t $$IMAGE_NAME ./output/$(notdir $@) && \ echo -n "Built image $$IMAGE_NAME of size: " && \ docker images $$IMAGE_NAME --format "{{.Size}}" && \ - echo full_image_name=$$IMAGE_NAME >> $GITHUB_OUTPUT && \ - echo image_tag=$(TAG) && \ - echo image_repo=$${REPO} + echo "::set-output name=full_image_name::$$IMAGE_NAME" && \ + echo "::set-output name=image_tag::$(TAG)" && \ + echo "::set-output name=image_repo::$${REPO}" post-build/%: export REPO?=$(DEFAULT_REPO) post-build/%: export TAG?=$(DEFAULT_TAG)