Skip to content

Commit 57f6c14

Browse files
committed
speedup build
1 parent ea19d0d commit 57f6c14

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

.github/workflows/build-image.yaml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
name: Build docker Image
22

3-
env:
4-
IMAGE_PLATFORMS: linux/386,linux/amd64,linux/arm64,linux/arm/v7,linux/ppc64le
5-
63
on:
74
workflow_dispatch:
85
push:
@@ -29,6 +26,10 @@ jobs:
2926
echo "::set-output name=tag::$(git describe --abbrev=0)"
3027
3128
build-image:
29+
strategy:
30+
matrix:
31+
platforms: [linux/386,linux/amd64,linux/arm64,linux/arm/v7,linux/ppc64le]
32+
3233
runs-on: ubuntu-latest
3334
needs: generate_tag
3435
steps:
@@ -45,7 +46,7 @@ jobs:
4546
- name: Set up QEMU
4647
uses: docker/setup-qemu-action@v1
4748
with:
48-
platforms: ${{ env.IMAGE_PLATFORMS }}
49+
platforms: ${{ matrix.platforms }}
4950
- name: Set up Docker Buildx
5051
id: buildx
5152
uses: docker/setup-buildx-action@v1
@@ -55,7 +56,7 @@ jobs:
5556
with:
5657
builder: ${{ steps.buildx.outputs.name }}
5758
context: ./docker-image/
58-
platforms: ${{ env.IMAGE_PLATFORMS }}
59+
platforms: ${{ matrix.platforms }}
5960
push: true
6061
tags: |
6162
ghcr.io/${{ github.repository }}:latest

0 commit comments

Comments
 (0)