]> git.ipfire.org Git - thirdparty/systemd.git/commit
fstab-generator: use log message that matches reality 25723/head
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 13 Dec 2022 13:38:06 +0000 (14:38 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Wed, 14 Dec 2022 21:12:44 +0000 (22:12 +0100)
commitc41fff1e0897df5731881225d831febaebf70413
treefce810c6e8d0806bc08abcda6b94dbe3efe52e4f
parent9f563f2792e17fba3474dc197034a24c1628ef26
fstab-generator: use log message that matches reality

We *assume* that when /sys is read-only, we're running in a container. But
there can other reasons, for example root is mount ro and nobody has mounted
/sys yet, or somebody forgot to add /sys to the list of filesystem not to
remount ro in a sandbox. So let's actually say what we know instead of assuming.

systemd-fstab-generator was reporting that it's running in a container and I
spent a good few minutes trying to figure out why 'systemd-detect-virt -c'
disagrees, before noticing that it's just checking a different condition.
src/fstab-generator/fstab-generator.c