Daan De Meyer [Mon, 6 Jan 2025 15:30:23 +0000 (16:30 +0100)]
fmf: Support being used downstream in dist-git tests
We can use our upstream fmf definitions to run downstream tests in
the Fedora systemd dist-git repository
(https://src.fedoraproject.org/rpms/systemd). To have access to the
dist-git sources when running the tests, we enable dist-git-source: true
downstream which makes the sources available in $TMT_SOURCE_DIR so
let's make sure we use those sources if they're available.
Yu Watanabe [Mon, 6 Jan 2025 13:13:50 +0000 (22:13 +0900)]
sd-varlink: add flag for sd_varlink_server for creating connections w… (#35841)
…ith fd passing enabled
Let's add a simple flag that enables fd passing for all connections of a
server. It's much easier to use this than to install a connect handler
which manually enables this for each connection.
Luca Boccassi [Mon, 6 Jan 2025 11:06:23 +0000 (11:06 +0000)]
sd-device: fix validation for devices under /sys/firmware/ in sd_device_new_from_subsystem_sysname() (#35863)
Devices under /sys/firmware/ do not have subsystems. Hence, the
validation in sd_device_new_from_subsystem_sysname() ->
device_new_from_path_join() always failed.
sd-varlink: add flag for sd_varlink_server for creating connections with fd passing enabled
Let's add a simple flag that enables fd passing for all connections of a
server. It's much easier to use this than to install a connect handler
which manually enables this for each connection.
Daan De Meyer [Fri, 20 Dec 2024 14:34:13 +0000 (15:34 +0100)]
packit: Move fmf metadata into upstream
This moves https://src.fedoraproject.org/tests/systemd into upstream
so it's one less moving piece that we need to remember. While we're at
it, do various cleanups as well:
- Remove non-packit logic
- Set NO_BUILD in mkosi.local.conf as it's not picked up from the
process environment
- Don't set unused environment variables
- Remove workdir logic as we run in an ephemeral VM already
- Drop --verbose from meson test to reduce noise
from passed tests
- Use mkosi sandbox and drop duplicated deps from metadata file
- Stop running the unit tests as they already run as part of the rpm
build and as part of the integration tests.
- Various style fixes
Daan De Meyer [Sun, 5 Jan 2025 22:19:44 +0000 (23:19 +0100)]
mkosi: Make path exclude more generic
The systemd rpms we try to install in packit have /usr/bin/bash and
/usr/bin/python3 as dependencies which breaks dnf5 because mkosi
doesn't download filelists metadata and
https://bugzilla.redhat.com/show_bug.cgi?id=2263771 is still not fixed
almost a year after being reported.
Yu Watanabe [Sat, 4 Jan 2025 18:52:05 +0000 (03:52 +0900)]
sd-device: fix validation for devices under /sys/firmware/ in sd_device_new_from_subsystem_sysname()
Devices under /sys/firmware/ do not have subsystems. Hence, the
validation in sd_device_new_from_subsystem_sysname() ->
device_new_from_path_join() always failed.
Mike Yuan [Wed, 27 Nov 2024 15:35:11 +0000 (16:35 +0100)]
namespace-util: modernize fd_is_namespace() and is_our_namespace()
- Make fd_is_namespace() take NamespaceType
- Drop support for kernel without NS_GET_NSTYPE (< 4.11)
- Port is_our_namespace() to namespace_open_by_type()
(preparation for later commits, where the latter
would go by pidfd if available, avoiding procfs)
Luca Boccassi [Sat, 4 Jan 2025 12:04:02 +0000 (12:04 +0000)]
mkosi: update debian commit reference
* 5d185f7901 Install new files for upstream CI
* c6484e14fc Update changelog for 257.1-7 release
* 543c1e6a42 d/t/tests-in-lxd: more fixes for debci compatibility
* a7d4a7ffa3 Add missing d/copyright file to signed template packages
* ab48efa495 Install new files for upstream CI
* d0cae6d06c Update changelog for 257.1-6 release
* 2fd23ffaaa Drop build dependency on libxen-dev on armhf, no longer available
* 35fbac92a5 d/t/upstream: update mkosi setting name
* 4d9862709e d/t/tests-in-lxd: drop auto-apt-proxy.conf from container
* cf133a8d32 Update changelog for 257.1-5 release
* 77ec315ec5 d/t/upstream: switch from btrfs to ext4 and use nspawn again
* 9c57f51fb8 d/t/upstream: do not mask machined and instead use mkosi workaround
* eb8b91d98b d/t/upstream: do not use --verbose with 'meson test'
* 21c65b7e22 d/t/tests-in-lxd: auto-apt-proxy is in universe in Ubuntu
* 081a78884b d/t/tests-in-lxd: install auto-apt-proxy in the nested container
* faa014a64e Update changelog for 257.1-4 release
* 4a48235928 Backport patch to workaround issue in new mdadm
* 005390f039 d/t/upstream: mask systemd-machined
* f7c86d8ec3 d/t/upstream: disable homed/userdbd in the test runner
* a1c30e55e0 d/t/upstream: do not use nspawn for tests
* 9bad1d3021 d/t/upstream: decrease parallelism to nproc - 1
* 7d1d583d7b Update changelog for 257.1-3 release
* dfe5996032 autopkgtest: mark tests-in-lxd as flaky
* 331567b13d d/t/upstream: disable ToolsTree= in mkosi config
* 04af5d8604 Update changelog for 257.1-2 release
* 2e58f0092c d/t/tests-in-lxd: use a single autopkgtest invocation
* 4b608de1d2 d/t/tests-in-lxd: prefer $AUTOPKGTEST_TMP to manual discovery
* fb4f3e4272 d/t/tests-in-lxd: do not fail if /etc/apt/sources.list.d/autopkgtest.list does not exist
* 385bbd0147 d/t/tests-in-lxd: set -x to get more logs
* ab678ff879 d/t/tests-in-lxd: quote variables to fix shellcheck warning
* 0d0eb96f16 d/t/tests-in-lxd: workaround broken os-release in sid
* 916a518d8e d/t/tests-in-lxd: use correct lxc image for debian
* 97deb28f99 Update changelog for 257.1-1 release
* 6276567a1d Install systemd-creds bash completion
* 084248775c Drop patches, merged upstream
* c4aa4ac6bd Update upstream source from tag 'upstream/257.1'
* dffde7eae8 d/watch: restrict to v257.x series
* 3c5143991c d/t/tests-in-lxd: fix autopkgtest source dir
* 5626a78ad1 systemd-ukify: recommend python3-cryptography
* ca5fdf7bc5 d/t/control: move tests-in-lxd above upstream suite
* 71c3f1014c d/systemd-resolved.postinst: copy existing /etc/resolv.conf on new installs
* 6ca4f4c1e5 d/control: make systemd-sysv Depends: on matching version of systemd
* eae57033c2 debian/control: add Breaks: systemd (<< ${binary:Version}) for udev
* 408cc1872c debian/systemd.postinst: Skip daemon-reexec and try-restarts during shutdown
* 6b3a01118b debian/tests/boot-and-services: drop test_no_failed
* 5a333eef8c d/t/tests-in-lxd: run some tests under LXD
* 882d221400 d/t/upstream: fix mkosi syntax warnings
Daan De Meyer [Fri, 3 Jan 2025 19:27:05 +0000 (20:27 +0100)]
mkosi: Handle directories in debian/not-installed correctly (#35832)
If a directory is specified without a glob pattern, we have to exclude
all files in that directory, so add a recursive glob to every directory
and enable the bash globstar feature when globbing to '**/*' matches all
files and directories beneath the given directory.
Daan De Meyer [Fri, 3 Jan 2025 15:45:50 +0000 (16:45 +0100)]
core: do not disconnect from bus when failed to install signal match (#35779)
If bus_add_match_full() is called without install callback and we failed
to install the signal match e.g. by timeout, then add_match_callback()
will disconnect from the bus. Let's use a custom install handler and
handle failures gracefully.
This does not *solve* the root cause of issue
https://github.com/systemd/systemd/issues/30573, but should improve the
situation when the issue is triggered.
The new json_dispatch_const_path() is to json_dispatch_path() what
sd_json_dispatch_const_string() is to sd_json_dispatch_ string(), i.e.
doesn't implicitly strdup() the string, but gives you the pointer into
the JSON structure, and thus requires you to keep it pinned.
Daan De Meyer [Fri, 3 Jan 2025 12:54:09 +0000 (13:54 +0100)]
vmspawn: Switch to virtconsole for headless console (#35836)
virtconsole is the modern way to set up a headless serial connection
to a virtual machine so let's make use of it instead of -serial. This
also allows us to get rid of the per architecture serial console device
names and makes vmspawn more consistent with mkosi qemu which already
uses
virtconsole.
Daan De Meyer [Fri, 3 Jan 2025 09:20:45 +0000 (10:20 +0100)]
mkosi: Handle directories in debian/not-installed correctly
If a directory is specified without a glob pattern, we have to exclude
all files in that directory, so add a recursive glob to every directory
and enable the bash globstar feature when globbing to '**/*' matches all
files and directories beneath the given directory.
Otherwise the code was measuring the content of hwdids into dtbauto
section and vice-versa.
Found this while adding the new `dtbauto` and `.hwdids` fields in the go
implementation of `sd-measure` at
https://github.com/siderolabs/talos/blob/main/internal/pkg/secureboot/measure/measure.go.