From 181dbdaf579563d00f17d5148d717c768ca325d8 Mon Sep 17 00:00:00 2001 From: Ryan Northey Date: Wed, 4 Sep 2024 12:12:35 +0100 Subject: [PATCH] release/ci: Fix Dockerhub publishing Signed-off-by: Ryan Northey --- .github/workflows/_publish_build.yml | 6 ++++++ .github/workflows/envoy-publish.yml | 8 ++++++++ 2 files changed, 14 insertions(+) diff --git a/.github/workflows/_publish_build.yml b/.github/workflows/_publish_build.yml index 857a2cf56b49..7e12c2a2280d 100644 --- a/.github/workflows/_publish_build.yml +++ b/.github/workflows/_publish_build.yml @@ -6,6 +6,10 @@ permissions: on: workflow_call: secrets: + dockerhub-username: + required: false + dockerhub-password: + required: false gpg-key: required: true gpg-key-password: @@ -128,6 +132,8 @@ jobs: source: | export NO_BUILD_SETUP=1 export ENVOY_DOCKER_IN_DOCKER=1 + export DOCKERHUB_USERNAME=${{ secrets.dockerhub-username }} + export DOCKERHUB_PASSWORD=${{ secrets.dockerhub-password }} trusted: ${{ inputs.trusted }} upload-name: docker upload-path: build_images diff --git a/.github/workflows/envoy-publish.yml b/.github/workflows/envoy-publish.yml index d4703d50bc1d..5d4b5fa1af6d 100644 --- a/.github/workflows/envoy-publish.yml +++ b/.github/workflows/envoy-publish.yml @@ -55,6 +55,14 @@ jobs: contents: read packages: read secrets: + dockerhub-username: >- + ${{ fromJSON(needs.load.outputs.trusted) + && secrets.DOCKERHUB_USERNAME + || '' }} + dockerhub-password: >- + ${{ fromJSON(needs.load.outputs.trusted) + && secrets.DOCKERHUB_PASSWORD + || '' }} gpg-key: ${{ fromJSON(needs.load.outputs.trusted) && secrets.ENVOY_GPG_MAINTAINER_KEY || secrets.ENVOY_GPG_SNAKEOIL_KEY }} gpg-key-password: >- ${{ fromJSON(needs.load.outputs.trusted)