Update to mkosi v19
- Use mkosi.images/ instead of mkosi.presets/ - Use the .chroot suffix to run scripts in the image - Use BuildSources= match for the kernel build - Move 10-systemd.conf to mkosi.conf and rely on mkosi.local.conf for local configuration
This commit is contained in:
@@ -81,11 +81,11 @@ jobs:
|
||||
echo 'deb http://azure.archive.ubuntu.com/ubuntu jammy-proposed restricted main universe' | sudo tee /etc/apt/sources.list.d/proposed.list
|
||||
|
||||
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11
|
||||
- uses: systemd/mkosi@16e63baaeadf7a5b100c5b5bf780c61c29878cfc
|
||||
- uses: systemd/mkosi@bbe715f42911f9660712377a5b39335b9391ae22
|
||||
|
||||
- name: Configure
|
||||
run: |
|
||||
tee mkosi.conf <<- EOF
|
||||
tee mkosi.local.conf <<- EOF
|
||||
[Distribution]
|
||||
Distribution=${{ matrix.distro }}
|
||||
Release=${{ matrix.release }}
|
||||
@@ -112,17 +112,17 @@ jobs:
|
||||
# For erofs, we have to install linux-modules-extra-azure, but that doesn't match the running kernel
|
||||
# version, so we can't load the erofs module. squashfs is a builtin module so we use that instead.
|
||||
|
||||
mkdir -p mkosi.presets/system/mkosi.repart/10-usr.conf.d
|
||||
tee mkosi.presets/system/mkosi.repart/10-usr.conf.d/squashfs.conf <<- EOF
|
||||
mkdir -p mkosi.images/system/mkosi.repart/10-usr.conf.d
|
||||
tee mkosi.images/system/mkosi.repart/10-usr.conf.d/squashfs.conf <<- EOF
|
||||
[Partition]
|
||||
Format=squashfs
|
||||
EOF
|
||||
|
||||
# The emergency shell is not useful in the CI, as it just blocks for a long time before the job
|
||||
# eventually times out. Override it to just shutdown immediately.
|
||||
mkdir -p mkosi.presets/initrd/mkosi.extra/usr/lib/systemd/system/emergency.service.d/
|
||||
mkdir -p mkosi.presets/system/mkosi.extra/usr/lib/systemd/system/emergency.service.d/
|
||||
tee mkosi.presets/initrd/mkosi.extra/usr/lib/systemd/system/emergency.service.d/poweroff.conf <<- EOF
|
||||
mkdir -p mkosi.images/initrd/mkosi.extra/usr/lib/systemd/system/emergency.service.d/
|
||||
mkdir -p mkosi.images/system/mkosi.extra/usr/lib/systemd/system/emergency.service.d/
|
||||
tee mkosi.images/initrd/mkosi.extra/usr/lib/systemd/system/emergency.service.d/poweroff.conf <<- EOF
|
||||
[Unit]
|
||||
FailureAction=exit
|
||||
[Service]
|
||||
@@ -130,7 +130,7 @@ jobs:
|
||||
ExecStart=
|
||||
ExecStart=false
|
||||
EOF
|
||||
cp mkosi.presets/initrd/mkosi.extra/usr/lib/systemd/system/emergency.service.d/poweroff.conf mkosi.presets/system/mkosi.extra/usr/lib/systemd/system/emergency.service.d/poweroff.conf
|
||||
cp mkosi.images/initrd/mkosi.extra/usr/lib/systemd/system/emergency.service.d/poweroff.conf mkosi.images/system/mkosi.extra/usr/lib/systemd/system/emergency.service.d/poweroff.conf
|
||||
|
||||
- name: Generate secure boot key
|
||||
run: mkosi --debug genkey
|
||||
|
||||
Reference in New Issue
Block a user