Skip to content

Commit c8e2110

Browse files
committed
ci: tag latest in the same step [skip ci]
1 parent 526d06e commit c8e2110

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

.github/workflows/CI.yml

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -258,17 +258,7 @@ jobs:
258258
context: .
259259
file: ./dev/docker/ci/${{ matrix.container.file }}
260260
push: ${{ github.event_name != 'pull_request' }}
261-
tags: ${{ vars.DOCKERHUB_USERNAME }}/${{ matrix.container.image }}:${{ matrix.container.tag }}
262-
263-
- name: Tag
264-
run: |
265-
docker tag ${{ vars.DOCKERHUB_USERNAME }}/${{ matrix.container.image }}:${{ matrix.container.tag }} ${{ vars.DOCKERHUB_USERNAME }}/${{ matrix.container.image }}:latest
266-
267-
- name: Push Latest
268-
if: ${{ github.event_name != 'pull_request' }}
269-
run: |
270-
docker login -u ${{ vars.DOCKERHUB_USERNAME }} -p ${{ secrets.DOCKERHUB_TOKEN }}
271-
docker push ${{ vars.DOCKERHUB_USERNAME }}/${{ matrix.container.image }}:latest
261+
tags: ${{ vars.DOCKERHUB_USERNAME }}/${{ matrix.container.image }}:${{ matrix.container.tag }},${{ vars.DOCKERHUB_USERNAME }}/${{ matrix.container.image }}:latest
272262

273263
- name: Test
274264
uses: docker/build-push-action@v5

0 commit comments

Comments
 (0)