Skip to content

Commit 502d850

Browse files
authored
tag remove 参数
1 parent a425601 commit 502d850

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

.github/workflows/mirror.yaml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,7 @@ on:
2323
description: '空间名称'
2424
required: true
2525
default: 'dockerhub_mirror'
26-
TARGET_ARCH:
27-
description: '平台 amd64(默认)、arm64、arm/v7'
28-
required: false
26+
2927
jobs:
3028
build:
3129
runs-on: ubuntu-latest
@@ -37,11 +35,7 @@ jobs:
3735

3836
- name: Pull, tag, and push Docker image
3937
run: |
40-
if [ "${{ github.event.inputs.TARGET_ARCH }}" != "" ]; then
41-
docker pull --platform ${{ github.event.inputs.TARGET_ARCH }} ${{ github.event.inputs.IMAGE_NAME }}:${{ github.event.inputs.IMAGE_VERSION }}
42-
else
43-
docker pull ${{ github.event.inputs.IMAGE_NAME }}:${{ github.event.inputs.IMAGE_VERSION }}
44-
fi
38+
docker pull ${{ github.event.inputs.IMAGE_NAME }}:${{ github.event.inputs.IMAGE_VERSION }}
4539
docker tag ${{ github.event.inputs.IMAGE_NAME }}:${{ github.event.inputs.IMAGE_VERSION }} ${{ github.event.inputs.TARGET_REGISTRY }}/${{ github.event.inputs.TARGET_REPOSITORY }}/${{ github.event.inputs.NEW_NAME }}:${{ github.event.inputs.IMAGE_VERSION }}
4640
docker push ${{ github.event.inputs.TARGET_REGISTRY }}/${{ github.event.inputs.TARGET_REPOSITORY }}/${{ github.event.inputs.NEW_NAME }}:${{ github.event.inputs.IMAGE_VERSION }}
4741

0 commit comments

Comments
 (0)