From d4151e53e05b0f693c07549496d30b655212a863 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Fri, 8 Nov 2024 16:54:22 +0100 Subject: [PATCH] feat: use containerd backend That should allow to load multiarch images. --- .github/workflows/docker.yml | 38 ++++++++++++++---------------------- 1 file changed, 15 insertions(+), 23 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index d8081b6..7fb346a 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -25,6 +25,9 @@ jobs: - name: Set up QEMU uses: docker/setup-qemu-action@v3 + - name: Set up containerd + uses: crazy-max/ghaction-setup-containerd@v3 + - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 @@ -65,6 +68,18 @@ jobs: type=edge,branch=main type=sha,format=long + - name: Build and push (base) + uses: docker/build-push-action@v6 + with: + context: base + push: ${{ github.event_name != 'pull_request' }} + tags: ${{ steps.base.outputs.tags }} + labels: ${{ steps.base.outputs.labels }} + platforms: linux/amd64,linux/arm64 + cache-from: type=gha + cache-to: type=gha,mode=max + load: true + - name: Docker meta (dev) id: dev uses: docker/metadata-action@v5 @@ -84,29 +99,6 @@ jobs: type=edge,branch=main type=sha,format=long - - name: Build and push (base) - uses: docker/build-push-action@v6 - with: - context: base - push: ${{ github.event_name != 'pull_request' }} - tags: ${{ steps.base.outputs.tags }} - labels: ${{ steps.base.outputs.labels }} - platforms: linux/amd64,linux/arm64 - cache-from: type=gha - cache-to: type=gha,mode=max - - # This build should be cached, but needed to load - # image for dev container as load does not work with multiple - # platforms - - name: Build and load (base) - uses: docker/build-push-action@v6 - with: - context: base - tags: ${{ steps.base.outputs.tags }} - labels: ${{ steps.base.outputs.labels }} - load: true - cache-from: type=gha - - name: Build and push (dev) uses: docker/build-push-action@v6 with: