Commit Graph
75 Commits
Author SHA1 Message Date
Christian Brauner 7849500cd9 mkosi: install bpftool in Debian/Ubuntu test images
The centos-fedora, opensuse and postmarketos image configurations all
install bpftool but the Debian/Ubuntu ones never did. Only their build
image gets it via the packaging's Build-Depends. So the
TEST-90-RESTRICT-FSACCESS guard and overlay subtests, both gated on
'command -v bpftool', just silently skip there.

Mirror what the build image does. Plain bpftool everywhere except Ubuntu
jammy and noble which still bundle it in linux-tools-generic.

Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
2026-08-10 16:09:06 +02:00
Luca Boccassi f029c336e9 mkosi: stage volatile deb packages for upgrade test
Prepare scripts run before volatile packages are installed, so parse
the list from the config to ensure they are all included to avoid
failures due to some packages missing from the list.

Follow-up for 28e1f84d6a
2026-07-30 09:13:35 +01:00
Luca Boccassi bbc5511d6a test: add deb coverage and a few more sanity checks to TEST-88-UPGRADE (#43162) 2026-07-26 17:41:16 +01:00
Luca Boccassi 28e1f84d6a test: add deb coverage to TEST-88-UPGRADE 2026-07-26 13:45:28 +01:00
Yu Watanabe facb0c20af mkosi: drop references to EOL fedora releases 2026-07-26 20:45:43 +09:00
Luca Boccassi 0b57cfd797 mkosi: pull new split-out packages for deb/ubuntu 2026-06-27 10:20:47 +01:00
Yu Watanabe 1a787e5195 mkosi: add postmarketos support
postmarketOS image can be built with for example the following mkosi.local.conf:
```
[Distribution]
Distribution=postmarketos

[Output]
Format=disk

[Build]
UseSubvolumes=yes

[Runtime]
Firmware=uefi
```
2026-06-27 00:18:16 +09:00
Luca Boccassi 1bab6341cc mkosi: drop obsolete systemd-boot-debuginfo suse package
No longer exists since latest spec changes, as the binaries have
moved to another package so it doesn't get autogenerated anymore

Follow-up for db9d7265f5
2026-06-17 10:55:50 +01:00
Luca Boccassi 10f8544727 mkosi: fix various TriggerMatch conditions
TriggerMatch is an AND by default, so when multiple
Release matches are defined, they need to be prefixed by '|'
2026-06-04 16:07:29 +01:00
Luca Boccassi c310106c15 test: install python package needed by networkd-tests.py
systemd-networkd-tests.py[515]: Failed to import either platform or packaging module, assuming the comparison failed
2026-05-25 14:45:29 +01:00
Daan De Meyer 73fd578f86 mkosi: drop libucontext again
Turns out it's possible to implement fibers without unnecessary
system calls and without ucontext.h so there's no need for libucontext
anymore, so drop it from the package list.
2026-05-08 22:38:31 +01:00
Daan De Meyer bb17ded158 mkosi: Install liburing
Make sure liburing is installed so it's available for 
experimentation in sd-event integration.
2026-04-29 09:20:57 +01:00
vlefebvre 14c7014d7f mkosi: user and group bin needed for a test
* Fix the test TEST-02-UNITTESTS for openSUSE environment.
2026-04-23 17:15:06 +01:00
Daan De Meyer 909efb6f2e shared: load libgnutls and libmicrohttpd via dlopen
Convert the GnuTLS and libmicrohttpd usage in journal-remote to the
dlopen pattern used by other optional shared libraries. A new
src/shared/gnutls-util.{h,c} declares the GnuTLS entry points via
DLSYM_PROTOTYPE and resolves them in dlopen_gnutls(); microhttpd-util
is moved from src/journal-remote to src/shared and gains analogous
DLSYM_PROTOTYPEs plus dlopen_microhttpd(). Callers in journal-gatewayd,
journal-remote-main and microhttpd-util itself call the sym_* wrappers
and invoke dlopen_gnutls()/dlopen_microhttpd() at their entry points.

setup_gnutls_logger() no longer fails when libgnutls is missing at
runtime; it logs a notice and returns 0 so journal-gatewayd starts up
without TLS dependencies installed.

The meson files gain libgnutls_cflags and libmicrohttpd_cflags partial
dependencies that expose include paths and compile flags only. Every
systemd-journal-{gatewayd,remote,upload} target switches to the cflags
variant, dropping the direct libgnutls/libmicrohttpd link. The
gatewayd->remote object-sharing dance for microhttpd-util.o goes away
since the code now lives in libshared.

test-dlopen-so gains assertions for dlopen_gnutls and dlopen_microhttpd.
2026-04-23 06:41:05 +02:00
Christian Brauner d32bc9cd07 vmspawn: add integration test for machinectl VM control verbs
Add TEST-87-AUX-UTILS-VM.vmspawn.sh that validates the QMP-varlink
bridge end-to-end using a real QEMU instance:

- Launches vmspawn with --directory and --linux for direct kernel boot
  (no UEFI firmware or bootable image needed)
- Waits for machine registration with machined
- Verifies varlinkAddress is exposed in Machine.List
- Tests machinectl pause, resume, poweroff
- Exercises MachineInstance varlink interface directly via varlinkctl:
  QueryStatus state verification across pause/resume, Pause, Resume

Skipped automatically if vmspawn, QEMU, or a bootable kernel is not
available. Runs as part of TEST-87-AUX-UTILS-VM in the mkosi
integration test suite.

Signed-off-by: Christian Brauner (Amutable) <brauner@kernel.org>
2026-04-15 10:14:48 +02:00
Luca Boccassi 1d6585f218 mkosi: pull in gnu coreutils for Ubuntu 26.04 and newer
The default coreutils in Ubuntu 26.04 moved to uutils, which is broken
in many subtle and annoying ways, breaking various tests. It's also
a giant monolithic megabinary which makes the minimal image size
go up and break other tests.

Force the gnu coreutils to be pulled in all images.
2026-03-27 23:08:35 +00:00
Lennart Poettering 056c21aaeb tpm2: add "systemd-tpm2-swtpm" wrapper for "swtpm"
For TPM-less systems it's sometimes valuable to have a fill-in software
TPM running from early boot on, so that TPM-based functionality can
"just work" and rely on TPM semantics, even if it's at a substantially
weaker security level.

This adds a wrapper around swtpm. It's a binary that chainloads swtpm
but does a few preparatory steps and integrates into systemd's logic
otherwise.

All this is then exposed as systemd-tpm2-swtpm.service.

The service is not hooked into much yet, that is added in later commits.
2026-03-26 16:11:34 +01:00
Daan De Meyer 4e77671be7 mkosi: Remove some packages from the image
Let's slim down the image size a bit. None of the removed packages
should be required.
2026-02-15 12:51:00 +00:00
Luca Boccassi 7755127ca5 mkosi: isc-dhcp-server was dropped from debian testing/unstable 2026-02-09 20:03:38 +00:00
Luca Boccassi 8fe50c025b mkosi: always install util-linux-script in Fedora
F41 is EOL, so we can unconditionally install this package, so that we
don't have to add a new version every time a new release is branched

Fixes test issues such as:

TEST-74-AUX-UTILS.sh[1363]: .//usr/lib/systemd/tests/testdata/units/TEST-74-AUX-UTILS.networkctl.sh: line 55: script: command not found
2026-02-08 15:42:43 +01:00
Daan De Meyer 81a43a44eb mkosi: Install libucontext in Arch/Fedora images
Split out of #39771

We don't use make use of libucontext yet but merging this early makes
sure my mkosi cached images don't get invalidated every time I switch
between my other work and the fiber branch.
2026-01-21 12:02:52 +01:00
Yu Watanabe ff9c4ace70 mkosi/opensuse: do not build/install systemd-sysvcompat package
The package is now empty. It is not necessary to build it.

This also drops unnecessary modifications for files.*.
2026-01-18 15:49:37 +09:00
Yu Watanabe d207be293c Drop support for SysV rc-local script support
As already announced for several years.
2026-01-16 22:56:28 +09:00
Maximilian Bosch db5f1952f3 mkosi: /bin/bash -> /usr/bin/env bash
This is analogous to a change in mkosi[1] with the same motivation: some
scripts are run to bootstrap the distribution tree and are thus running
directly on the host system which may not have `/bin/bash` (e.g. NixOS).

As with the `mkosi` change, do that for each shebang for consistency
reasons.

[1] https://github.com/systemd/mkosi/commit/8d2cd50e5192cada7211724ecff3514f0c85cf0f
2026-01-11 06:57:49 +01:00
Daan De Meyer fb514c2f8f mkosi: Rework how the pkgenv environment variables are set
Instead of including distribution specific files in the subimages,
let's have one common mkosi.pkgenv/ directory that handles all the
matching which is then included in the subimages.

This gives us more control on exactly how we do the matching.
2025-11-25 11:02:34 +01:00
Daan De Meyer e1f9de9739 mkosi: update fedora commit reference to 12f95f807fef5075a8842dd107f83b4c41d5ac26
* 12f95f807f Wrap %autosetup in %_build_in_place check
* f9916b6fd1 Revert "Use %autosetup -C"
* 044cff4700 Allow empower group
* a0acca210d Version 259~rc1
* e455d82fd8 Add various extra explicit Requires
* 1a7506a105 Version 258.2
* 256463d690 Restore runlevelX.target units
* b17d9c3474 Use %autosetup -C
* fe18084a05 Remove hack to stop systemd-networkd-resolve-hook.socket
2025-11-20 15:26:26 +01:00
Luca Boccassi 5b3874929a mkosi: update debian commit reference to efdd7a6377c7251011ca2c1a59115d482d25fe61
* efdd7a6377 Install new file for upstream build
* 9ebdc6099e d/rules: enable 10-systemd-logind-root-ignore-inhibitors.rules.example on Ubuntu
* 1255cc7663 initramfs-tools: only skip chzdev rules if zdev_early=0
* 4675b281ee d/t/boot-and-services: skip apparmor test on armhf
* 214d6e37b2 d/t/boot-and-services: run transient unit to check syslog messages
* f4e196aa26 d/t/boot-and-services: tweak test_rsyslog regex
* dbd366a43e Install new files for upstream build
* bb7f8ef532 Install new files for upstream build
* efa7cee8a7 Install new file for upstream build
* 95aa1d1685 Install new file for upstream build
* b770f0f01b kernel-install: skip 55-initrd.install when an initrd generator is configured
* af8d1e3134 Update changelog for 258.1-2 release
* 2d0e73cd14 d/libnss-systemd.postinst: Ensure module is enabled for all four databases
2025-11-12 23:39:45 +00:00
Zbigniew Jędrzejewski-Szmek 9218e4eacc mkosi: update fedora commit reference to 8e2833a5b64f7e2ce62ea0a2d0ec9e393e718dfa
* 8e2833a5b6 Automatically figure out the name of the top-level tar dir
* dffbf2beba Make sure fallback source is listed first
* 1d3b892105 Enable sysupdate and sysupdated
2025-11-03 13:31:22 +01:00
Daan De Meyer 16f4bc90d2 mkosi: update fedora commit reference to ea1d871ecd6c2fe063523840c1e4cf9bcf200e32
* ea1d871ecd Add missing networkd socket units
* b76b5da2e6 Merge #214 `Drop backwards compat logic from integration tests script`
* 7208fa2b1b Require systemd-rpm-macros for build
* 2e1a6c7474 Require python3-zstandard in ELN
* 79c9db1bc8 Require systemd-libs and systemd-shared to be in the same version
* db38445a7e Drop two patches with workaround (selinux, kernel)
* 593a204189 Version 258.1
* a3e9e27982 Change '%{systemd}' to systemd in Conflicts/Provides/Requires/Recommends
* 88877a4184 Require systemd-networkd and systemd-udev to be in the same version
* 8a446daec7 Version 258 💝
* cceac93491 Pre-create /etc/userdb directory
* b442086d5f Version 258~rc4
* 327e54e421 Add to patch to create userdb root directory with correct label
* 2289d65726 Fix unit name in scriptlet
* 5acde9f1fd Add workaround patch to hopefully pass podman CI tests
* 1f5ed0da1f Version 258~rc3
* 50936458a7 obs: move recipe files in place
* 1bdb4efe40 obs: switch to xz for compression
* be7a4d0863 Version 258~rc2
* 2ace9416e8 obs: also use version with tilde for Source0
* 8d1645af75 Use again %{version} when building in OBS
* 98cc5fd91a Version 258~rc1
* ed7d2f1132 Add "test" that LTO effectively removes unused code from shared lib
* 40b38a04d2 Build docs on 64-bit architectures only
* 5d30fd3b26 Version 257.7
2025-10-30 14:56:41 +01:00
Daan De Meyer 7a18a538ef mkosi: Stop installing devel packages
These aren't required for tests and pull in a bunch of dependencies,
so let's not install them into the final image.
2025-10-24 12:59:11 +01:00
Thomas Blume 4c7e30c4e0 test: add policy packages for TEST-06-SELINUX in openSUSE 2025-10-24 12:58:32 +01:00
Luca Boccassi d62ab43fd0 mkosi: update debian commit reference to 5650452e6b0b430f44d3d48b7322c2b3c8b9477f
* 5650452e6b Install new files for upstream build
* 607afcd060 salsa: disable arm64/ppc64el again
* b1bb6d4849 systemd-tests: drop unused overrides
* b3790a36ca getty-static: add missing Documentation=
* 1cea27caba Backport patch to fix autopkgtest with new util-linux due to file move
* 2e74a7f969 Update changelog for 258.1-1 release
* 9250e242b9 Make /run/lock world writable by default
2025-10-22 20:06:44 +02:00
Luca Boccassi dc567bc406 mkosi: install new knot-keymgr in Fedora rawhide
https://src.fedoraproject.org/rpms/knot/c/52aa1c6b27ca981abe9960c0a4161be7204be75e

TEST-75-RESOLVED.sh[116]: + keymgr . generate algorithm=ECDSAP256SHA256 ksk=yes zsk=yes
TEST-75-RESOLVED.sh[454]: /usr/lib/systemd/tests/testdata/units/TEST-75-RESOLVED.sh: line 153: keymgr: command not found
2025-10-17 18:35:29 +01:00
Frantisek Sumsal f50e6fd897 mkosi: explicitly pull in libz1 on OpenSUSE
Otherwise it pulls in libz-ng-compat1 which isn't 100% compatible with
libz1, and more importantly it requires an ldconfig drop-in in /etc/
(/etc/ld.so.conf.d/zlib-ng-compat-x86_64.conf) which breaks hermetic-usr
and TEST-07-PID1:

systemd[5582]: /usr/lib/systemd/systemd: error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or directory
2025-10-14 17:29:58 +01:00
Frantisek Sumsal 4d8e8d44ab mkosi: install test dependencies for EnterNamespace= test
The test for the EnterNamespace= feature [0] has been both broken and
disabled since the migration to the mkosi framework, as it's missing the
libdw.pc file for pkg-config, so the test is skipped completely, and
it's also missing gcc to actually build the test binary.

[0] Part of TEST-87-AUX-UTILS-VM.coredump.sh
2025-10-11 22:37:33 +02:00
Luca Boccassi 29c639887a mkosi: update debian commit reference to e50fce1d4b2a9f1bb990027de8e86603f3b42301
* e50fce1d4b Fix installation of new manpages
* 8b45d3d793 Install new files for upstream build
* a401468f75 autopkgest: install bsdutils and bsdextrautils for unit tests
* 587584577e Explicitly disable bpf-framework for stage1 builds
* 209a8475d9 systemd: recommend login package
2025-10-05 22:11:40 +01:00
Luca Boccassi 6602a5f720 mkosi: pull in new knot package for TEST-75-RESOLVED
5728s TEST-75-RESOLVED.sh[439]: /usr/lib/systemd/tests/testdata/units/TEST-75-RESOLVED.sh: line 154: keymgr: command not found

The command was split out into a new package
2025-10-05 17:20:29 +01:00
Luca Boccassi d5eb732724 mkosi: pull in bsdutils for script, used by various integration tests
4971s TEST-74-AUX-UTILS.sh[1212]: + script -ec 'networkctl edit --runtime "$NETWORK_NAME"' /dev/null
4971s TEST-74-AUX-UTILS.sh[1269]: .//usr/lib/systemd/tests/testdata/units/TEST-74-AUX-UTILS.networkctl.sh: line 55: script: command not found

Currently works due to a transitive dependency somewhere else
that is being dropped, pull it in directly given the tool is
used by the tests
2025-09-25 15:11:17 +01:00
Luca Boccassi 2183d881b9 mkosi: update debian commit reference to 49dd9371a0c0dd08c7847c5885722eab88ac279f
* 49dd9371a0 d/rules: Ubuntu moved vmlinux.h too
* c81ce364eb Install new files for upstream build
* 35abaf33bc Override more Lintian warnings about appstream
* a3d3690c45 Override Lintian warning for appstream-metadata-missing-modalias-provide
* 1bcda1fd90 Override Lintian warning for binaries-have-file-conflict
* c597c00ffc Drop versioned conflicts added for bullseye upgrades
* 9cd845af25 Override lintian warnings for conflicts-with-version
* 359da95d09 Override Lintian warning for spare-manual-page
* 3ef8c31cb2 Override Lintian warning for groff-message
* dbe51582a9 Update changelog for 258-1 release
* ffd971a27d autopkgtest: ensure /usr/sbin is in the PATH for unit-tests job
* f086b8e881 autopkgtest: enable debug logs for unit-tests job
* 02142b9eae autopkgest: install dosfstools for test-loop-block
* 0319d890bd salsa-ci: enable ppc64el builds
* 645b1fa318 autopkgtest: use -20 instead of -22 for zstd compression
* b8dc9b0ce7 salsa-ci: switch to recommended entry point yml
* 152a2b3140 autopkgtest: set default_device_timeout_sec=240
* 6d46436878 autopkgtest: manually compress logs on failure
* c6c70bbb0c Update changelog for 258~rc4-1 release
* 2695112df7 Update changelog for 258~rc3-1 release
* 2c293cb2be systemd-boot: update version for rm_conffile
2025-09-24 00:38:40 +01:00
Yu Watanabe f8d5efc703 mkosi: drop man package from global config
Some distributions does not have man package, but named man-db or so,
and most distribution specific mkosi.conf files already have them.
Let's drop man from the global config.
2025-09-17 22:21:11 +09:00
val4oss 8fe3bd54be mkosi conf opensuse: ukify from systemd-ukify
* openSUSE tumbleweed moves ukify tool from systemd-experimental to
  systemd-ukify.

Signed-off-by: val4oss <github.widget541@passmail.net>
2025-09-16 17:10:46 +02:00
val4oss be285a9918 mkosi: update opensuse commit reference to 7d9cf5c934705c175766eaa688baa503da84e06a
* 7d9cf5c9347 Update systemd to version 257.9 / rev 456 via SR 1303345
* 439d743e5d6 Update systemd to version 257.7 / rev 455 via SR 1297651
* 4f72c6a6279 Update systemd to version 257.7 / rev 454 via SR 1296831
* 3b0afa5c6d1 Update systemd to version 257.7 / rev 453 via SR 1294979
* d0eccd20f5a Update systemd to version 257.7 / rev 452 via SR 1292221
* f9d183f8c57 Update systemd to version 257.7 / rev 451 via SR 1291008
* cbd6908247d Update systemd to version 257.7 / rev 450 via SR 1289968
* 6e5c00f9f92 Update systemd to version 257.6 / rev 449 via SR 1286997

Signed-off-by: val4oss <github.widget541@passmail.net>
2025-09-16 17:10:46 +02:00
val4oss 6becea2859 mkosi conf opensuse: add libtss2-tcti-device0 dep
* Add the TPM recommended package for opensuse mkosi conf to fix the
  TEST-70-TPM failure.

Signed-off-by: val4oss <github.widget541@passmail.net>
2025-09-12 10:34:02 +01:00
Daan De Meyer b21f52b6d1 mkosi: Install libcap-progs in main and minimal image
Let's make sure tools like capsh are available on OpenSUSE images
as well.
2025-09-05 08:24:39 +02:00
val4oss 0c7764f2a7 mkosi conf opensuse: add systemd-journal-remote
* Add the missing package for mkosi opensuse conf, otherwise TEST-04-JOURNAL
  fails with "/usr/lib/systemd/systemd-journal-remote: No such file or
  directory"

Signed-off-by: val4oss <github.widget541@passmail.net>
2025-09-04 17:32:18 +01:00
Luca Boccassi ec9b149bb2 mkosi: update debian commit reference to 8ba719208ff28f36bc240328725eb10008838c39
* 8ba719208f systemd-boot: install kernel hooks to /usr/share/
* c4d6093398 Update changelog for 258~rc2-2 release
* b21987b0f9 More NEWS updates about sysv support
* cd7d07f66b NEWS: fixlets and adjustments
* 34ef04cb45 Stop installing /var/lib/systemd in the package
* 08b77c5b7c Update changelog for 258~rc2-1 release
* 48b3ec2b9a systemd-container: update lintian overrides for more false positives
* 31547d827b systemd-boot: make efibootmgr a dependency
* 88a7261c00 d/t/control: prefer systemd-boot-tools if available
* 478ea8945f systemd-boot: fix registering/removing uncompressed kernels
* b072f60375 NEWS: fix typo
* 985a3c8d56 systemd-boot: register interest in systemd-boot-signed trigger
* f13b262bf6 d/rules: set debugoptimized for upstream builds
* 615f8851e8 Install usr/share/factory files and restore nsswitch.conf/pam.d/issue on factory reset
* 61792528f2 Update changelog for 258~rc1-1 release
* 116371a1df d/copyright: update paths
* 41437c9c54 Add a few more conflicts to packages providing the same files
* 0e5eea70fd Fix Lintian warning debian-news-entry-uses-asterisk
* 60595acb01 Update Lintian overrides
* b8662ba796 Update symbols file for 258~rc1
* 58553602ca NEWS: note removal of telinit/runlevel
* d78ade0842 Drop all workarounds that are obsolete after trixie
* 7ef47f9f6b Drop world-writable /run/lock debianism
* 9d6d3a4154 NEWS: note cgroupv1 removal
* ef2ef6f35d Enable sd-vmspawn
* ac2aec3b68 Add and remove files for 258~rc1
* 06582be4e6 d/watch: remove restriction to v257.x series
* 88ccb1552a salsa-ci: enable arm64 build
2025-08-16 12:11:46 +01:00
Luca Boccassi 57aeb4a403 mkosi: install util-linux-script on F44
Once F41 is EOL we can just move this to the main list and
stop doing this dance every 6 months
2025-08-14 18:18:27 +01:00
Franck Bui 1f05d6a0de mkosi: include ip in the main image
It's needed by TEST-85-NETWORK.
2025-08-07 15:34:01 +01:00
Yu Watanabe 48bc6f47ea mkosi: update debian commit reference to 61144ff7a6747bd3cc6340fbac38a8e15e9a239b
* 61144ff7a6 Install new quota manpages for upstream build
* a50c51d8c8 systemd-boot: fix initramfs post-update hook for uncompressed kernels
2025-07-16 05:50:01 +09:00
Yu Watanabe f12cc0d3be mkosi: update debian commit reference to a8ad8e30e70c0b82ecb8fe016f2dde3a084236f0
* a8ad8e30e7 Stop installing legacy sysv tools/units for upstream builds
* 9856b1b1bd Install new files for upstream build
* b68bfb52d4 Update changelog for 257.7-2 release
* 3bd5f6d2e0 systemd-boot-tools: change architecture to linux-any
* 057ce29542 Move bootctl zsh completion file too to new package
* b47be01659 Revert "Revert installing systemd-networkd-varlink.socket"
* 71a425dd3b ukify: recommend sbsigntool | pesign for signing
* 54f67475ee Revert installing systemd-networkd-varlink.socket
2025-07-13 05:49:09 +09:00