]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
tests: don't fail directory CI if lvm2-monitor.service fails
authorJörg Behrmann <behrmann@physik.fu-berlin.de>
Tue, 21 Jan 2025 14:57:19 +0000 (15:57 +0100)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Wed, 22 Jan 2025 19:46:51 +0000 (20:46 +0100)
This service sometimes fails in CI for the arch:directory combination, e.g.

2025-01-21T12:07:33.4370559Z [   14.125731] mkosi-check-and-shutdown.sh[419]: + systemctl --failed --no-legend
2025-01-21T12:07:33.4380022Z [   14.126655] mkosi-check-and-shutdown.sh[420]: + tee /failed-services
2025-01-21T12:07:33.4714973Z [   14.160448] mkosi-check-and-shutdown.sh[420]: ● lvm2-monitor.service not-found failed failed lvm2-monitor.service
2025-01-21T12:07:33.4751355Z [   14.164135] mkosi-check-and-shutdown.sh[418]: + [[ ! -s /failed-services ]]

This is the first time this appears in the partcular boot's logs and we always
ignore it and carry on. Let's sidestep checking whether it is this particular
error by masking the unit.

A possible reason might be that it gets pulled in by udev if a test using LVM
runs first.

mkosi.postinst

index d5bd991bd8595a99e243c85c8ed5c125312a44bf..3201196ebcf84aa1fd7c7dfb56250f93fca42eca 100755 (executable)
@@ -16,3 +16,5 @@ mkosi-chroot \
     --groups "$SUDO_GROUP",systemd-journal \
     --shell /bin/bash \
     mkosi
+
+systemctl --root="$BUILDROOT" mask lvm2-monitor.service