添加 Docker Hub 构建支持

This commit is contained in:
xxnuo
2025-07-21 12:27:59 +08:00
parent 375adc3966
commit 7ed030d700

View File

@@ -51,11 +51,13 @@ jobs:
with:
images: |
ghcr.io/${{ github.repository }}
${{ secrets.DOCKERHUB_USERNAME }}/${{ github.event.repository.name }}
tags: |
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=raw,value=latest,enable=${{ github.ref_type == 'tag' }}
- name: Build and push standard image
uses: docker/build-push-action@v4
@@ -74,11 +76,13 @@ jobs:
with:
images: |
ghcr.io/${{ github.repository }}
${{ secrets.DOCKERHUB_USERNAME }}/${{ github.event.repository.name }}
tags: |
type=ref,event=branch,suffix=-zh
type=ref,event=pr,suffix=-zh
type=semver,pattern={{version}}-zh
type=semver,pattern={{major}}.{{minor}}-zh
type=raw,value=latest-zh,enable=${{ github.ref_type == 'tag' }}
- name: Build and push Chinese model image
uses: docker/build-push-action@v4
@@ -101,11 +105,13 @@ jobs:
with:
images: |
ghcr.io/${{ github.repository }}
${{ secrets.DOCKERHUB_USERNAME }}/${{ github.event.repository.name }}
tags: |
type=ref,event=branch,suffix=-ja
type=ref,event=pr,suffix=-ja
type=semver,pattern={{version}}-ja
type=semver,pattern={{major}}.{{minor}}-ja
type=raw,value=latest-ja,enable=${{ github.ref_type == 'tag' }}
- name: Build and push Japanese model image
uses: docker/build-push-action@v4