Files
nginx-proxy-manager-mcp/.github/workflows/docker.yml
T
b3nw 4a95ccd1b5 fix(#2): add multi-architecture Docker builds for arm64 support
Adds QEMU emulation setup and specifies platforms: linux/amd64,linux/arm64
in the GitHub Actions Docker build workflow. This fixes the ARM64 manifest
error ('no matching manifest for linux/arm64/v8') on Apple Silicon Macs.

Changes:
- Add docker/setup-qemu-action@v3 step before Buildx setup
- Add platforms: linux/amd64,linux/arm64 to build-push-action

Closes #2

Co-authored-by: claw-io <agent@ben.io>
2026-06-08 14:08:09 +00:00

60 lines
1.5 KiB
YAML

name: Build and Push Docker Image
on:
push:
branches: [main]
tags: ['v*']
pull_request:
branches: [main]
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Log in to Container Registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata (tags, labels)
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=raw,value=latest,enable={{is_default_branch}}
- name: Build and push Docker image
uses: docker/build-push-action@v6
with:
context: .
push: ${{ github.event_name != 'pull_request' }}
platforms: linux/amd64,linux/arm64
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max