Skip to content

Commit 3743929

Browse files
committed
fix: Push Docker Image do not work with Uppercase repository name
issue: codefresh-contrib#62
1 parent fffb30b commit 3743929

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

.github/workflows/docker-publish.yml

+7-4
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ env:
2020
# Use docker.io for Docker Hub if empty
2121
REGISTRY: ghcr.io
2222
# github.repository as <account>/<repo>
23-
IMAGE_NAME: ${{ github.repository }}
23+
# IMAGE_NAME: ${{ github.repository }}
2424

2525

2626
jobs:
@@ -45,6 +45,11 @@ jobs:
4545
password: ${{ secrets.GITHUB_TOKEN }}
4646

4747

48+
- id: imagename
49+
uses: ASzc/change-string-case-action@v2
50+
with:
51+
string: ${{ github.repository }}
52+
4853
# Build and push Docker image with Buildx (don't push on PR)
4954
# https://github.com/docker/build-push-action
5055
- name: Build and push Docker image
@@ -54,7 +59,5 @@ jobs:
5459
context: ./image-updater/source-code
5560
file: ./image-updater/source-code/Dockerfile
5661
push: true
57-
tags: ghcr.io/${{ github.repository }}:${{ inputs.docker_tag }}
58-
59-
62+
tags: ghcr.io/${{ steps.imagename.outputs.lowercase }}:${{ inputs.docker_tag }}
6063

0 commit comments

Comments
 (0)