From a4b6bf4f391ead3ba9d0cd7f07eccc5790ae384f Mon Sep 17 00:00:00 2001 From: Hampus Carlsson Date: Tue, 26 Nov 2024 22:37:09 +0100 Subject: [PATCH 1/3] Use lowercase repo name for ghcr image Instead of using hardcoded image name, take it from the repo name. This makes it work well for forks. --- .github/workflows/container-image.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/container-image.yaml b/.github/workflows/container-image.yaml index 8a4028ef..450108f5 100644 --- a/.github/workflows/container-image.yaml +++ b/.github/workflows/container-image.yaml @@ -25,11 +25,15 @@ jobs: steps: - uses: actions/checkout@v4.1.1 + - name: Generate downcase repository name + run: | + echo "REPO=${GITHUB_REPOSITORY,,}" >> ${GITHUB_ENV} + - name: Docker meta id: meta uses: docker/metadata-action@v5 with: - images: ghcr.io/ionos-cloud/cluster-api-provider-proxmox + images: ghcr.io/${{ env.REPO }} - name: Login to GitHub Container Registry if: github.event_name != 'pull_request' From 7c6d659c923cdf38927de42dbb117662843256dc Mon Sep 17 00:00:00 2001 From: Mohamed Chiheb Ben Jemaa Date: Wed, 27 Nov 2024 12:31:10 +0100 Subject: [PATCH 2/3] Update container-image.yaml --- .github/workflows/container-image.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/container-image.yaml b/.github/workflows/container-image.yaml index 450108f5..e25850b3 100644 --- a/.github/workflows/container-image.yaml +++ b/.github/workflows/container-image.yaml @@ -27,7 +27,7 @@ jobs: - name: Generate downcase repository name run: | - echo "REPO=${GITHUB_REPOSITORY,,}" >> ${GITHUB_ENV} + echo "REPO=${GITHUB_REPOSITORY,,}" >> "${GITHUB_ENV}" - name: Docker meta id: meta From 82af86eb075d50b58e3d33cd10c4aa6c557e7b28 Mon Sep 17 00:00:00 2001 From: Mohamed Chiheb Ben Jemaa Date: Wed, 27 Nov 2024 14:13:56 +0100 Subject: [PATCH 3/3] Update container-image.yaml --- .github/workflows/container-image.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/container-image.yaml b/.github/workflows/container-image.yaml index e25850b3..a630a5b6 100644 --- a/.github/workflows/container-image.yaml +++ b/.github/workflows/container-image.yaml @@ -25,7 +25,7 @@ jobs: steps: - uses: actions/checkout@v4.1.1 - - name: Generate downcase repository name + - name: Generate lowercase repository name run: | echo "REPO=${GITHUB_REPOSITORY,,}" >> "${GITHUB_ENV}"