This commit is contained in:
star7th
2025-04-10 20:34:49 +08:00
parent 2ee38ff763
commit 837ca687fc
3 changed files with 76 additions and 2 deletions
+23
View File
@@ -41,6 +41,7 @@ jobs:
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=sha,format=short
type=raw,value=latest,enable=${{ github.ref == 'refs/heads/master' }}
- name: Build and push
uses: docker/build-push-action@v4
@@ -50,4 +51,26 @@ jobs:
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
- name: Extract metadata for ARM Docker
id: meta-arm
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request'
uses: docker/metadata-action@v4
with:
images: star7th/jisuxiang
tags: |
type=raw,value=arm-latest
- name: Build and push ARM version
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request'
uses: docker/build-push-action@v4
with:
context: .
file: ./Dockerfile-ARM
push: true
platforms: linux/arm64
tags: ${{ steps.meta-arm.outputs.tags }}
labels: ${{ steps.meta-arm.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max