Skip to content

Commit 216468f

Browse files
committed
chore: fix repo name
1 parent b74a9e4 commit 216468f

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

.github/workflows/publish_ghcr.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,25 +30,28 @@ jobs:
3030
username: ${{ github.actor }}
3131
password: ${{ secrets.GITHUB_TOKEN }}
3232

33-
- name: Extract version from tag
33+
- name: Extract version from tag and set lowercase repo owner
3434
id: extract_version
3535
run: |
3636
REF_NAME=${GITHUB_REF#refs/tags/}
3737
VERSION=${REF_NAME#v}
38+
REPO_OWNER=$(echo $GITHUB_REPOSITORY_OWNER | tr '[:upper:]' '[:lower:]')
3839
echo "VERSION=$VERSION" >> $GITHUB_ENV
3940
echo "version=$VERSION" >> $GITHUB_OUTPUT
41+
echo "repo_owner=$REPO_OWNER" >> $GITHUB_OUTPUT
4042
4143
- name: Build and push Docker image
4244
uses: docker/build-push-action@v4
4345
env:
4446
VERSION: ${{ steps.extract_version.outputs.version }}
47+
REPO_OWNER: ${{ steps.extract_version.outputs.repo_owner }}
4548
with:
4649
context: .
4750
push: true
4851
platforms: linux/amd64,linux/arm64/v8
4952
tags: |
50-
ghcr.io/${{ github.repository_owner.toLowerCase() }}/etherproxy:${{ env.VERSION }}
51-
ghcr.io/${{ github.repository_owner.toLowerCase() }}/etherproxy:latest
53+
ghcr.io/${{ env.REPO_OWNER }}/etherproxy:${{ env.VERSION }}
54+
ghcr.io/${{ env.REPO_OWNER }}/etherproxy:latest
5255
labels: |
5356
org.opencontainers.image.version=${{ env.VERSION }}
5457
org.opencontainers.image.source=${{ github.server_url }}/${{ github.repository }}

0 commit comments

Comments
 (0)