mirror of
https://github.com/dgtlmoon/changedetection.io.git
synced 2025-12-15 04:26:14 +00:00
Build test - Build test for platforms in parallel
This commit is contained in:
37
.github/workflows/test-container-build.yml
vendored
37
.github/workflows/test-container-build.yml
vendored
@@ -25,6 +25,25 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
test-container-build:
|
test-container-build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
# Main Dockerfile platforms
|
||||||
|
- platform: linux/amd64
|
||||||
|
dockerfile: ./Dockerfile
|
||||||
|
- platform: linux/arm64
|
||||||
|
dockerfile: ./Dockerfile
|
||||||
|
- platform: linux/arm/v7
|
||||||
|
dockerfile: ./Dockerfile
|
||||||
|
- platform: linux/arm/v8
|
||||||
|
dockerfile: ./Dockerfile
|
||||||
|
- platform: linux/arm64/v8
|
||||||
|
dockerfile: ./Dockerfile
|
||||||
|
# Alpine Dockerfile platforms (musl via alpine check)
|
||||||
|
- platform: linux/amd64
|
||||||
|
dockerfile: ./.github/test/Dockerfile-alpine
|
||||||
|
- platform: linux/arm64
|
||||||
|
dockerfile: ./.github/test/Dockerfile-alpine
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- name: Set up Python 3.11
|
- name: Set up Python 3.11
|
||||||
@@ -47,26 +66,14 @@ jobs:
|
|||||||
version: latest
|
version: latest
|
||||||
driver-opts: image=moby/buildkit:master
|
driver-opts: image=moby/buildkit:master
|
||||||
|
|
||||||
# https://github.com/dgtlmoon/changedetection.io/pull/1067
|
- name: Test that the docker containers can build (${{ matrix.platform }} - ${{ matrix.dockerfile }})
|
||||||
# Check we can still build under alpine/musl
|
|
||||||
- name: Test that the docker containers can build (musl via alpine check)
|
|
||||||
id: docker_build_musl
|
|
||||||
uses: docker/build-push-action@v6
|
|
||||||
with:
|
|
||||||
context: ./
|
|
||||||
file: ./.github/test/Dockerfile-alpine
|
|
||||||
platforms: linux/amd64,linux/arm64
|
|
||||||
cache-from: type=gha
|
|
||||||
cache-to: type=gha,mode=max
|
|
||||||
|
|
||||||
- name: Test that the docker containers can build
|
|
||||||
id: docker_build
|
id: docker_build
|
||||||
uses: docker/build-push-action@v6
|
uses: docker/build-push-action@v6
|
||||||
# https://github.com/docker/build-push-action#customizing
|
# https://github.com/docker/build-push-action#customizing
|
||||||
with:
|
with:
|
||||||
context: ./
|
context: ./
|
||||||
file: ./Dockerfile
|
file: ${{ matrix.dockerfile }}
|
||||||
platforms: linux/amd64,linux/arm64,linux/arm/v7,linux/arm/v8,linux/arm64/v8
|
platforms: ${{ matrix.platform }}
|
||||||
cache-from: type=gha
|
cache-from: type=gha
|
||||||
cache-to: type=gha,mode=max
|
cache-to: type=gha,mode=max
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user