virtualisation.lxc: replace /sbin/init on switch

in the future maybe a proper shim-bootloader could be used that supports 
switching out /sbin/init (so nixos-rebuild boot would just switch the 
link)
This commit is contained in:
Maciej Krüger
2021-05-01 00:23:45 +02:00
parent 8eac2a669a
commit fec499bb98

View File

@@ -143,6 +143,10 @@ in
# Allow the user to login as root without password.
users.users.root.initialHashedPassword = mkOverride 150 "";
system.activationScripts.installInitScript = mkForce ''
ln -fs $systemConfig/init /sbin/init
'';
# Some more help text.
services.getty.helpLine =
''