nixos/systemd-stage-1: follow systemd /run propagation

We currently bypass systemd's switch-root logic by premounting
/sysroot/run. Make sure to propagate its sub-mounts with the recursive
flag, in accordance with the default switch-root logic.

This is required for creds at /run/credentials to survive the transition
from initrd -> host.
This commit is contained in:
Peter Marshall
2025-05-28 13:02:39 -04:00
parent aeb017b583
commit 7d36daa76a
+1 -1
View File
@@ -642,7 +642,7 @@ in
{
where = "/sysroot/run";
what = "/run";
options = "bind";
options = "rbind";
unitConfig = {
# See the comment on the mount unit for /run/etc-metadata
DefaultDependencies = false;