alter workflow to push different tags

This commit is contained in:
guochao 2025-02-19 20:05:16 +08:00
parent a253d0bf9d
commit fc98377c9a

View File

@ -41,5 +41,9 @@ jobs:
- name: Login to Container Registry
run: echo "${{ secrets.ACTION_PACKAGE_WRITE_TOKEN }}" | podman login ${{ github.server_url }} -u ${{ github.repository_owner }} --password-stdin
- name: Push Container Image
run: REGISTRY=${{ github.server_url}}; REGISTRY=${REGISTRY##https://}; REGISTRY=${REGISTRY##http://}; podman push --log-level=trace $REGISTRY/${{ github.repository }}
run: REGISTRY=${{ github.server_url}}; REGISTRY=${REGISTRY##https://}; REGISTRY=${REGISTRY##http://}; podman push $REGISTRY/${{ github.repository }} docker://$REGISTRY/${{ github.repository }}:dev
if: ${{ github.ref_type == "branch" && github.ref_name == "master" }}
- name: Push Container Image with Tag and Update latest image
run: REGISTRY=${{ github.server_url}}; REGISTRY=${REGISTRY##https://}; REGISTRY=${REGISTRY##http://}; podman push $REGISTRY/${{ github.repository }}; podman push $REGISTRY/${{ github.repository }} docker://$REGISTRY/${{ github.repository }}:${{ github.ref_name }}
if: ${{ github.ref_type == "tag" }}