]> git.ipfire.org Git - thirdparty/systemd.git/blame - .github/workflows/mkosi.yml
mkosi: update to latest commit
[thirdparty/systemd.git] / .github / workflows / mkosi.yml
CommitLineData
43d6fcc0
ZJS
1---
2# vi: ts=2 sw=2 et:
186b9041 3# SPDX-License-Identifier: LGPL-2.1-or-later
43d6fcc0 4# Simple boot tests that build and boot the mkosi images generated by the mkosi config files in mkosi.default.d/.
448d3462
DDM
5name: mkosi
6
448d3462
DDM
7on:
8 push:
9 branches:
9b25429c 10 - main
c76a8385 11 - v[0-9]+-stable
448d3462
DDM
12 pull_request:
13 branches:
9b25429c 14 - main
c76a8385 15 - v[0-9]+-stable
448d3462 16
e7a96691
EV
17permissions:
18 contents: read
311956cc 19
24acd406
FS
20env:
21 # Enable debug logging in systemd, but keep udev's log level to info,
22 # since it's _very_ verbose in the QEMU task
255963ec
LB
23 # Disable the ISC DHCP servers, as they are failing in Ubuntu
24 KERNEL_CMDLINE: "systemd.unit=mkosi-check-and-shutdown.service !quiet systemd.log_level=debug systemd.log_target=console udev.log_level=info systemd.default_standard_output=journal+console systemd.mask=isc-dhcp-server6.service systemd.mask=isc-dhcp-server.service"
24acd406 25
448d3462
DDM
26jobs:
27 ci:
f304d038 28 runs-on: ubuntu-22.04
38848376 29 concurrency:
3a2f1d19 30 group: ${{ github.workflow }}-${{ matrix.distro }}-${{ matrix.release }}-${{ github.ref }}
38848376 31 cancel-in-progress: true
448d3462
DDM
32 strategy:
33 fail-fast: false
34 matrix:
24a0df5c
DDM
35 include:
36 - distro: arch
37 release: rolling
38 - distro: debian
39 release: testing
40 - distro: ubuntu
aa1bf7e6 41 release: jammy
24a0df5c 42 - distro: fedora
e2c99d3b 43 release: "36"
2d625795
DDM
44 - distro: fedora
45 release: rawhide
24a0df5c
DDM
46 - distro: opensuse
47 release: tumbleweed
da637c8f
DDM
48 - distro: centos_epel
49 release: 9-stream
448d3462
DDM
50
51 steps:
5f994fff 52 - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b
31ed4b91 53 - uses: systemd/mkosi@ff0238897d52429d52071ffd0297948c9d6d7e1d
448d3462
DDM
54
55 - name: Install
392ed185 56 run: sudo apt-get update && sudo apt-get install --no-install-recommends python3-pexpect python3-jinja2
448d3462 57
7e99216c 58 - name: Configure
24a0df5c
DDM
59 run: |
60 tee mkosi.default <<- EOF
61 [Distribution]
62 Distribution=${{ matrix.distro }}
63 Release=${{ matrix.release }}
64
65 [Content]
66 Environment=CI_BUILD=1
67
68 [Output]
69 KernelCommandLine=${{ env.KERNEL_CMDLINE }}
70 EOF
6242cda9 71
448d3462 72 - name: Build ${{ matrix.distro }}
0e961391 73 run: sudo python3 -m mkosi build
448d3462 74
715a273b 75 - name: Show ${{ matrix.distro }} image summary
0e961391 76 run: sudo python3 -m mkosi summary
715a273b 77
448d3462 78 - name: Boot ${{ matrix.distro }} systemd-nspawn
0e961391 79 run: sudo python3 -m mkosi boot ${{ env.KERNEL_CMDLINE }}
24acd406
FS
80
81 - name: Check ${{ matrix.distro }} systemd-nspawn
0e961391 82 run: sudo python3 -m mkosi shell bash -c "[[ -e /testok ]] || { cat /failed-services; exit 1; }"
448d3462
DDM
83
84 - name: Boot ${{ matrix.distro }} QEMU
0e961391 85 run: sudo timeout -k 30 10m python3 -m mkosi qemu
24acd406
FS
86
87 - name: Check ${{ matrix.distro }} QEMU
0e961391 88 run: sudo python3 -m mkosi shell bash -c "[[ -e /testok ]] || { cat /failed-services; exit 1; }"