Skip to content

Commit 9b8b822

Browse files
committed
refactor
(cherry picked from commit eeb47d5)
1 parent 665902a commit 9b8b822

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed

.github/workflows/docker_publish.yml

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -79,19 +79,12 @@ jobs:
7979

8080
- name: Define env vars for container registry URL
8181
run: |
82-
if [ ${{ matrix.registry }} == 'public.ecr.aws' ]; then
83-
# vars.ECR_REGISTRY value is expected to be of the `public.ecr.aws/<public_ecr_id>` form
84-
# The `public_ecr_id` must be a *default* alias associated with public regsitry (rather
85-
# than a custom alias)
82+
if [ ${{ matrix.registry }} == 'ecr' ]; then
8683
echo "REGISTRY=${{ vars.ECR_REGISTRY }}" >> $GITHUB_ENV
87-
# Trim GH Org name so that resulting Public ECR URL has no duplicate org name
88-
# Public ECR default alias: public.ecr.aws/<public_ecr_id>/kafka-ui
89-
# Public ECR custom alias: public.ecr.aws/kafbat/kafka-ui
90-
echo "REPOSITORY=$(basename ${{ github.repository }})" >> $GITHUB_ENV
91-
else # this covers the case of docker.io and ghcr.io
84+
else
9285
echo "REGISTRY=${{ matrix.registry }}" >> $GITHUB_ENV
93-
echo "REPOSITORY=${{ github.repository }}" >> $GITHUB_ENV
9486
fi
87+
echo "REPOSITORY=${{ github.repository }}" >> $GITHUB_ENV
9588
9689
- name: Push images to ${{ matrix.registry }}
9790
run: |

0 commit comments

Comments
 (0)