sd-card-images CI #305
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: sd-card-images CI | |
on: | |
push: | |
branches: "*" | |
pull_request: | |
branches: | |
- "master" | |
schedule: | |
# Every Sunday morning | |
- cron: "00 03 * * 0" | |
jobs: | |
test-debian-x86: | |
runs-on: ubuntu-latest | |
name: test ${{ matrix.os }} ${{ matrix.arch }} ${{ matrix.suite }} | |
strategy: | |
matrix: | |
include: | |
- os: debian | |
suite: bullseye | |
arch: i386 | |
- os: debian | |
suite: bookworm | |
arch: i386 | |
- os: debian | |
suite: trixie | |
arch: i386 | |
- os: debian | |
suite: sid | |
arch: i386 | |
fail-fast: false | |
env: | |
DEBIAN_OS: ${{ matrix.os }} | |
DEBIAN_ARCH: ${{ matrix.arch }} | |
DEBIAN_SUITE: ${{ matrix.suite }} | |
steps: | |
- name: Install dependencies | |
timeout-minutes: 5 | |
env: | |
DEBIAN_FRONTEND: noninteractive | |
run: | | |
sudo apt-get update | |
sudo apt-get --assume-yes \ | |
--no-install-recommends \ | |
install bc \ | |
bison \ | |
bzip2 \ | |
ca-certificates \ | |
debian-archive-keyring \ | |
debootstrap \ | |
device-tree-compiler \ | |
dosfstools \ | |
e2fsprogs \ | |
flex \ | |
gcc \ | |
gcc-arm-none-eabi \ | |
gcc-i686-linux-gnu \ | |
git \ | |
libssl-dev \ | |
make \ | |
mtools \ | |
parted \ | |
pigz \ | |
pwgen \ | |
python2-dev \ | |
python3-dev \ | |
python3-pkg-resources \ | |
ssh \ | |
sshpass \ | |
swig \ | |
qemu-system-x86 | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build qemu_x86_virt | |
timeout-minutes: 5 | |
run: | | |
env PATH=$GITHUB_WORKSPACE/scripts:$PATH \ | |
ARTIFACTS_DIR=$RUNNER_TEMP \ | |
U_BOOT_GIT_REV="v2023.07" \ | |
U_BOOT_GIT_URL="https://github.com/u-boot/u-boot.git" \ | |
build-boot qemu_x86_virt \ | |
qemu-x86 \ | |
qemu-x86_defconfig \ | |
i686-linux-gnu | |
- name: Build ${{ matrix.suite }} ${{ matrix.arch }} | |
timeout-minutes: 5 | |
run: | | |
sudo env PATH=$GITHUB_WORKSPACE/scripts:$PATH \ | |
ARTIFACTS_DIR=$RUNNER_TEMP \ | |
build-debian $DEBIAN_OS \ | |
$DEBIAN_ARCH \ | |
$DEBIAN_SUITE | |
- name: Test qemu_x86_virt + ${{ matrix.suite }} ${{ matrix.arch }} | |
timeout-minutes: 15 | |
run: | | |
sudo ./test/qemu.sh $RUNNER_TEMP/boot-qemu_x86_virt.bin.gz \ | |
$RUNNER_TEMP/${{ matrix.os }}-${{ matrix.suite }}-${{ matrix.arch }}-*.bin.gz | |
build-docker: | |
runs-on: ubuntu-latest | |
needs: test-debian-x86 | |
name: build docker images | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Set up QEMU | |
timeout-minutes: 1 | |
uses: docker/setup-qemu-action@v2 | |
- name: Set up Docker Buildx | |
timeout-minutes: 1 | |
uses: docker/setup-buildx-action@v2 | |
- name: Build | |
timeout-minutes: 30 | |
uses: docker/build-push-action@v3 | |
with: | |
context: . | |
platforms: linux/amd64,linux/arm64 |