From afdf07cb9b8a71bf782178d0f2cd345e32ec3371 Mon Sep 17 00:00:00 2001 From: Lin Zhihao <59785146+LinZhihao-723@users.noreply.github.com> Date: Mon, 18 Dec 2023 18:05:43 -0500 Subject: [PATCH] Convert repository names to lowercase before using them in docker image names. (#187) --- .github/actions/clp-core-build-containers/action.yaml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/actions/clp-core-build-containers/action.yaml b/.github/actions/clp-core-build-containers/action.yaml index 4866761dd..0f1087b48 100644 --- a/.github/actions/clp-core-build-containers/action.yaml +++ b/.github/actions/clp-core-build-containers/action.yaml @@ -45,12 +45,16 @@ runs: echo "REGISTRY=localhost:${{inputs.local_registry_port}}" >> "$GITHUB_OUTPUT" echo "BRANCH=latest" >> "$GITHUB_OUTPUT" fi + # Docker doesn't support repository names with uppercase characters, so we convert to + # lowercase here. + echo "REPOSITORY=$(echo '${{github.repository}}' | tr '[:upper:]' '[:lower:]')" \ + >> "$GITHUB_OUTPUT" - id: "deps_image_meta" uses: "docker/metadata-action@v5" with: images: "${{steps.get_deps_image_props.outputs.REGISTRY}}\ - /${{github.repository}}\ + /${{steps.get_deps_image_props.outputs.REPOSITORY}}\ /clp-core-dependencies-x86-${{inputs.os_name}}" tags: | type=raw,value=${{steps.get_deps_image_props.outputs.BRANCH}} @@ -73,7 +77,7 @@ runs: uses: "docker/metadata-action@v5" with: images: "${{steps.get_deps_image_props.outputs.REGISTRY}}\ - /${{github.repository}}\ + /${{steps.get_deps_image_props.outputs.REPOSITORY}}\ /clp-core-x86-${{inputs.os_name}}" tags: | type=raw,value=${{steps.get_deps_image_props.outputs.BRANCH}}