diff --git a/.github/workflows/pipeline.yml b/.github/workflows/pipeline.yml index c20e8e0cd..b6ea73b71 100644 --- a/.github/workflows/pipeline.yml +++ b/.github/workflows/pipeline.yml @@ -168,6 +168,7 @@ jobs: id: check run: echo "is_enabled=${{ secrets.DOCKER_HUB_USERNAME != '' }}" >> $GITHUB_OUTPUT + build: name: Build needs: [js, go, go-lint, i18n-lint, git-version, check-push-enabled] @@ -188,6 +189,12 @@ jobs: run: | PLATFORM=$(echo ${{ matrix.platform }} | tr '/' '_') echo "PLATFORM=$PLATFORM" >> $GITHUB_ENV + + - name: Get Lowercase Name + id: lowercase_name + run: | + REPO_LOWER=$(echo "${{ github.repository }}" | tr '[:upper:]' '[:lower:]') + echo "REPO_LOWER=$REPO_LOWER" >> $GITHUB_ENV - uses: actions/checkout@v4 @@ -236,7 +243,7 @@ jobs: CROSS_TAGLIB_VERSION=${{ env.CROSS_TAGLIB_VERSION }} outputs: | type=image,name=${{ steps.docker.outputs.hub_repository }},push-by-digest=true,name-canonical=true,push=${{ steps.docker.outputs.hub_enabled }} - type=image,name=ghcr.io/${{ github.repository }},push-by-digest=true,name-canonical=true,push=true + type=image,name=ghcr.io/${{ env.REPO_LOWER }},push-by-digest=true,name-canonical=true,push=true - name: Export digest if: env.IS_LINUX == 'true' && env.IS_DOCKER_PUSH_CONFIGURED == 'true' && env.IS_ARMV5 == 'false' @@ -259,8 +266,6 @@ jobs: runs-on: ubuntu-latest needs: [build, check-push-enabled] if: needs.check-push-enabled.outputs.is_enabled == 'true' - env: - REGISTRY_IMAGE: ghcr.io/${{ github.repository }} steps: - uses: actions/checkout@v4 @@ -270,6 +275,14 @@ jobs: path: /tmp/digests pattern: digests-* merge-multiple: true + + - name: Get Lowercase Name + id: lowercase_name + run: | + REPO_LOWER=$(echo "${{ github.repository }}" | tr '[:upper:]' '[:lower:]') + echo "REPO_LOWER=$REPO_LOWER" >> $GITHUB_ENV + REGISTRY_IMAGE="ghcr.io/$REPO_LOWER" + echo "REGISTRY_IMAGE=$REGISTRY_IMAGE" >> $GITHUB_ENV - name: Prepare Docker Buildx uses: ./.github/actions/prepare-docker @@ -306,8 +319,8 @@ jobs: env: GH_TOKEN: ${{ github.token }} run: | - for artifact in $(gh api repos/${{ github.repository }}/actions/artifacts | jq -r '.artifacts[] | select(.name | startswith("digests-")) | .id'); do - gh api --method DELETE repos/${{ github.repository }}/actions/artifacts/$artifact + for artifact in $(gh api repos/${{ env.REPO_LOWER }}/actions/artifacts | jq -r '.artifacts[] | select(.name | startswith("digests-")) | .id'); do + gh api --method DELETE repos/${{ env.REPO_LOWER }}/actions/artifacts/$artifact done msi: