ci: add multi-platform Docker image support for ARM64 (#1180)

* Add support for multiple platforms in Docker build

* Enhance Docker workflow with QEMU and Buildx setup

Added steps to set up QEMU and Docker Buildx, and login to GitHub Container Registry.

* Refactor Docker workflow for improved clarity

* Remove duplicate GitHub CR login step

Removed duplicate login step for GitHub Container Registry in the Docker workflow.

* Reorder Docker Buildx setup in workflow

* Rename step to 'Docker Buildx' in workflow
This commit is contained in:
Vianney Veremme
2025-10-15 03:44:38 -04:00
committed by GitHub
parent 46a3861825
commit ddc57f21f9

View File

@@ -52,6 +52,10 @@ jobs:
echo "PUMPKIN_VERSION=$(echo $VERSION | cut -d '+' -f 1)" >> $GITHUB_ENV
echo "MC_VERSION=$(echo $VERSION | cut -d '+' -f 2)" >> $GITHUB_ENV
- name: Set up QEMU
if: steps.repo_check.outputs.should_deploy == 'true'
uses: docker/setup-qemu-action@v3
- name: Extract Metadata
if: steps.repo_check.outputs.should_deploy == 'true'
id: meta
@@ -74,7 +78,16 @@ jobs:
if: steps.repo_check.outputs.should_deploy == 'true'
uses: docker/build-push-action@v6
with:
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
annotations: ${{ steps.meta.outputs.annotations }}
- name: Generate SBOM
if: steps.repo_check.outputs.should_deploy == 'true'
uses: anchore/sbom-action@v0
with:
image: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
format: spdx-json
artifact-name: sbom-pumpkin-${{ env.PUMPKIN_VERSION }}