Skip to content

Commit e37f463

Browse files
committed
perf: replace / characters in branch name
1 parent 41170d8 commit e37f463

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

.github/workflows/az_acr_delete.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,13 @@ jobs:
2424
client-id: ${{ secrets.AZURE_CLIENT_ID }}
2525
tenant-id: ${{ secrets.AZURE_TENANT_ID }}
2626
subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
27+
28+
# - name: Log into registry
29+
# uses: docker/login-action@v3
30+
# with:
31+
# registry: "${{ env.AZURE_CONTAINER_REGISTRY }}"
32+
# username: "${{ env.ACR_LOGIN_USERNAME }}"
33+
# password: "${{ env.ACR_LOGIN_PASSWORD }}"
2734

2835
- name: Delete Test Container Image
2936
uses: azure/cli@v2

.github/workflows/az_acr_push.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ jobs:
2323
steps:
2424
- name: Checkout repository
2525
uses: actions/checkout@v4
26+
- name: Configure branch name
27+
id: branch_name
28+
run: echo "GH_REF_NAME=${GITHUB_REF_NAME//\//-}" >> $GITHUB_OUTPUT
2629
- name: Set up Docker Buildx
2730
uses: docker/setup-buildx-action@v3
2831
- name: Log into registry
@@ -44,13 +47,13 @@ jobs:
4447
platform=linux/${{ matrix.platform}}
4548
label=dockerfile-path=https://github.com/${{ github.repository }}/blob/${{ github.sha }}/Dockerfile
4649
47-
- name: Build & Push ${{ github.event.repository.name }}:${{ matrix.platform}}-${{ github.ref_name }}
50+
- name: Build & Push ${{ github.event.repository.name }}:${{ matrix.platform}}-${{ steps.branch_name.outputs.GH_REF_NAME }}
4851
if: ${{ github.ref != github.repository.default_branch }}
4952
uses: docker/build-push-action@v5
5053
with:
5154
push: true
5255
file: 'Dockerfile'
53-
tags: ${{ env.AZURE_CONTAINER_REGISTRY }}/${{ github.event.repository.name }}:${{ matrix.platform}}-${{ github.ref_name }}
56+
tags: ${{ env.AZURE_CONTAINER_REGISTRY }}/${{ github.event.repository.name }}:${{ matrix.platform}}-${{ steps.branch_name.outputs.GH_REF_NAME }} }}
5457
cache-from: type=gha
5558
cache-to: type=gha,mode=max
5659
build-args: |

0 commit comments

Comments
 (0)