Commit Graph

78981 Commits

Author SHA1 Message Date
Luca Boccassi
f6eed063a6 mkosi: switch rootfs to ext4
btrfs is currently broken for nspawn on recent kernels, so switch
to the best filesystem until that is solved
2025-01-22 22:50:52 +00:00
Luca Boccassi
338813351e udev-dump: also show written sysfs attributes and sysctl entries (#36091)
Split-out of #35968.
2025-01-22 20:56:31 +00:00
Luca Boccassi
60ca3caec6 OBS: switch to new top-level namespace (#36121)
https://build.opensuse.org/project/show/system:systemd
2025-01-22 20:50:44 +00:00
Luca Boccassi
a41f67b041 docs: mention packages in HACKING.md 2025-01-22 20:50:08 +00:00
Yu Watanabe
c1b7db56e5 udevadm-test: allow to specify extra directories to load udev rules files
This adds -D/--extra-rules-dir=DIR switch for 'udevadm test' command.
When specified, udev rules files in the specified directory will be also
loaded. This may be useful for debugging udev rules by copying some udev
rules files to a temporary directory.
2025-01-22 20:46:42 +00:00
Yu Watanabe
4fd81d03e2 rpm: mark udevd for reloading when an rules file is installed/updated
Then, we can avoid using udevadm (especially udev control socket) in
processing rpm.
2025-01-22 20:44:38 +00:00
Nick Rosbrook
16f99f5be9 udev: add systemd tag to devices tagged with security-device
This ensures that device units are created for these, which is
convenient for other units that want to declare dependencies on
such devices.
2025-01-22 21:43:44 +01:00
Lennart Poettering
af20b92b61 userdb: add comments to userdb varlink IDL 2025-01-22 21:42:14 +01:00
Lennart Poettering
347576ca8d machine-id-setup: actually unlink /run/machine-id if write/mount fails (#36105)
Follow-up for 64d52739c5

Fixes CID#1590374 and CID#1590375
2025-01-22 21:41:57 +01:00
Mike Yuan
9c039ef5ff pidfd-util: preferably acquire pidfd inode id through name_to_handle_at()
See rationales described in kernel commit:
b3caba8f7a
2025-01-22 21:41:44 +01:00
Lennart Poettering
cc524bc1fe userdb: two small fixes (#36115) 2025-01-22 21:41:28 +01:00
Lennart Poettering
593ad9746b fs-util: at_flags_normalize_nofollow() follow-up (#36116)
Just some extension to 6981203f3a
2025-01-22 21:41:14 +01:00
Luca Boccassi
13871aa656 OBS: switch to new top-level namespace
https://build.opensuse.org/project/show/system:systemd
2025-01-22 20:34:04 +00:00
Yu Watanabe
9ddcccfad7 udev-dump: also show written sysfs attributes and sysctl entries
This should be useful to know what is changed by processing an event.
2025-01-23 01:50:13 +09:00
Yu Watanabe
f3cbd4da12 udev-dump: voidify one function call
Fixes CID#1590377.
2025-01-23 01:50:13 +09:00
Lennart Poettering
4b11087b37 fs-util: also add an at_flags_normalize_follow() helper
This is the reverse of at_flags_normalize_follow()
2025-01-22 17:46:50 +01:00
Lennart Poettering
0783d8da50 xattr-util: use at_flags_normalize_nofollow() at one more place 2025-01-22 17:46:06 +01:00
Lennart Poettering
83e3b96d0a userdb: reset errno before getpwent()
errno handling for NSS is always a bit weird since NSS modules generally
are not particularly careful with it. Hence let's initialize errno
explicitly before we invoke getpwent() so that we know it's in a
reasonable state afterwards on failure, or zero if not.

We do this in most places we use NSS, including in userdb when it comes
to getgrent(), just for getpwent() we don't so far. Address that.
2025-01-22 17:41:12 +01:00
Lennart Poettering
165275fe80 userdbctl: don't expect argument to --fuzzy
The getopt() parser was completely wrong, it expected an argument where
wasn't expected or processes.

The test cases only passed by accident because they use the "user" verb
which is also the default verb. It would be accidently read as argument
for --fuzzy and ignored.

Fix that.
2025-01-22 17:40:05 +01:00
Daan De Meyer
d3d501e949 test: Make sure we run lcov from the meson source directory
In ac75c51927, we accidentally changed
the working directory that the tools executed in the wrapper script
are invoked in. This broke our invocations of lcov. Let's explicitly
run those in the meson source directory again to fix the coverage
workflow.
2025-01-23 01:32:37 +09:00
Léane GRASSER
e8908d2fc1 po: Translated using Weblate (French)
Currently translated at 100.0% (257 of 257 strings)

Co-authored-by: Léane GRASSER <leane.grasser@proton.me>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/fr/
Translation: systemd/main
2025-01-22 23:43:34 +09:00
Mike Yuan
c8650d0dbe machine-id-setup: fix typo 2025-01-22 14:47:57 +01:00
Mike Yuan
f389506714 machine-id-setup: actually unlink /run/machine-id if write/mount fails
Follow-up for 64d52739c5

Fixes CID#1590374 and CID#1590375
2025-01-22 14:47:37 +01:00
Yu Watanabe
e887b3006c networkd-test: unconditionally stop previous invocation of networkd before starting new one
When networkd is already running, creating some .network files and
friends and starting networkd does not take any effect. Let's always
restart networkd when we want to start a new invocation.
2025-01-22 10:29:59 +00:00
Lennart Poettering
8946dabaa3 mountpoint-util: several tweaks for fd_is_mount_point(), drop support for kernels without /proc/pid/fdinfo/ (#36093) 2025-01-22 09:37:25 +01:00
Mike Yuan
6cab0df904 mountpoint-util: port path_is_mount_point() to chase_and_open_parent() 2025-01-22 01:37:32 +01:00
Mike Yuan
7ce2c1bb5f mountpoint-util: rename fd_is_mount_point() to is_mount_point_at()
fd_* functions in our codebase usually mean fd-specific operations,
while this one actually takes openat()-style params. Rename it
accordingly hence.
2025-01-22 01:37:31 +01:00
Mike Yuan
e2f97c790e mountpoint-util: some tweaks for fd_is_mount_point()
- Drop fstat() fallback path now that we assume fdinfo
  is available
- Use at_flags_normalize_nofollow()
- Accept empty path the same way as NULL
- Accept fd being AT_FDCWD and filename being "."
2025-01-22 01:37:09 +01:00
Mike Yuan
e5a3127339 mountpoint-util: our baseline includes fdinfo and mnt_id now 2025-01-22 01:12:55 +01:00
Mike Yuan
229429a799 mountpoint-util: check >= 0 for success 2025-01-22 01:12:54 +01:00
Mike Yuan
c3b7f0240f mountpoint-util: update comment in is_name_to_handle_at_fatal_error()
We can now assume name_to_handle_at() syscall is available,
however the underlying fs can still lack support for it.
2025-01-22 01:12:10 +01:00
Mike Yuan
6981203f3a fs-util: introduce at_flags_normalize_nofollow() helper 2025-01-22 00:52:34 +01:00
Lennart Poettering
eab9b9b4ea update TODO 2025-01-21 23:06:55 +01:00
Lennart Poettering
bd9553d677 varlink: fix error name
The documentation and code agree on the same name, since always, but
when I put together the IDL I made a mistake and insert a "Not" that
wasn't supposed to be there.

Let's correct that.
2025-01-21 23:01:31 +01:00
Lennart Poettering
dc5af20b0c tree-wide: always include our own headers with "" rather than <>
We got this almost always right. Fix this for a few outliers.
2025-01-21 17:05:36 +00:00
Daan De Meyer
d641a1f8f7 mkosi: Various tools tree fixes (#36059) 2025-01-21 15:17:36 +01:00
Daan De Meyer
c0165676e9 TEST-74-AUX-UTILS: Move run0 pcrlock test to TEST-70-TPM
On CentOS Stream 9/10 booting mkosi qemu with --firmware=linux doesn't
add the virtual TPM to the virtual machine which means TEST-74-AUX-UTILS.run.sh
fails because it requires a TPM.

Let's move the systemd-pcrlock logic that requires a TPM to
TEST-70-TPM.pcrlock to avoid the problem.
2025-01-21 13:48:13 +01:00
Lennart Poettering
3c58ce6bae user-record/home: add concept of alias names for accounts (#36041) 2025-01-21 12:57:52 +01:00
Daan De Meyer
34da8dd345 test: Look for qemu in /usr/libexec/qemu-kvm as well
On CentOS Stream, the qemu binary is /usr/libexec/qemu-kvm so use
that if it's available.
2025-01-21 12:29:56 +01:00
Daan De Meyer
cb13d6b44f mkosi: Run more commands as root
zypper has some new rather questionable userspace level permission
checking that blows ups completely when operating as root on an
cache directory owned by a non-root user, so let's build the tools
tree and set up meson as root to avoid the issue.

(https://github.com/openSUSE/libzypp/issues/603)

Also drop a leftover debug message from coverage.yml while we're at
it.
2025-01-21 10:59:01 +01:00
Daan De Meyer
26025dba3e mkosi: Don't set -O ^orphan_file in centos stream 9 tools tree 2025-01-21 10:57:29 +01:00
Daan De Meyer
7a75a6f70f mkosi: lcov and shellcheck are not in EPEL 10
Let's drop these from CentOS Stream tools trees as they are not in
EPEL 10 yet.
2025-01-21 10:57:29 +01:00
Daan De Meyer
7645139bd7 mkosi: Use a bigger variety of tools tree distributions
Let's add more coverage for building with tools trees by building
each image with a tools tree of the same distribution and release.

Because not every tools tree distribution has a newer meson yet, we
only use --max-lines= when meson actually knows the option.
2025-01-21 10:57:29 +01:00
Daan De Meyer
685666afd8 mkosi: Update to latest 2025-01-21 10:57:27 +01:00
Lennart Poettering
3d3f27cd9a update TODO 2025-01-21 09:59:16 +01:00
Lennart Poettering
853e9b754a test: add test for homed alias and realm user resolution 2025-01-21 09:59:13 +01:00
Lennart Poettering
5cd7b455e0 homectl: add support for creating users with alias names 2025-01-21 09:59:09 +01:00
Lennart Poettering
40fd0e0423 homed: support user record aliases 2025-01-21 09:59:05 +01:00
Lennart Poettering
a642f9d2d3 pam_systemd_home: support login with alias names + user names with realms
This in particular makes sure that we normalize the user name and update
it in the PAM session, once we acquire it. This means that if you have a
user with name "a" and alias "b", and the user logs in as "b" they end
up properly with "a" as user name set, as intended by the PAM gods.

Moreover, if you have a user "c" in a ralm "d", they may log in by
specifying "c" or "c@d", with equivalent results.
2025-01-21 09:59:02 +01:00
Lennart Poettering
1fb53bb561 pam_systemd_home: use right field name in error message 2025-01-21 09:58:58 +01:00