bootvine restored systemd's status output as soon as a display manager took the console. greetd's Type=idle only waits five seconds, so jobs still running then wrote status lines over the login screen. Restore the output when StartupFinished arrives instead, through a single private path that owns the console watch. A quit key or stopping the service still restores it at once, so a stuck boot stays visible.
37 lines
987 B
Nix
37 lines
987 B
Nix
{ machine, ... }:
|
|
{
|
|
name = "bootvine-scripted-initrd";
|
|
|
|
nodes.machine =
|
|
{ lib, ... }:
|
|
let
|
|
waitFor = flag: "/bin/sh -c 'until [ -e /run/${flag} ]; do sleep 0.1; done'";
|
|
in
|
|
{
|
|
imports = [
|
|
machine
|
|
../shared/recorded-display.nix
|
|
];
|
|
systemd = {
|
|
settings.Manager.ShowStatus = lib.mkForce true;
|
|
services = {
|
|
sample-database.serviceConfig.ExecStop = lib.mkForce (waitFor "release-sample-database");
|
|
backdoor.before = [ "sample-database.service" ];
|
|
late-sensor-probe = {
|
|
wantedBy = [ "graphical.target" ];
|
|
after = [ "greetd.service" ];
|
|
serviceConfig = {
|
|
Type = "oneshot";
|
|
ExecStart = waitFor "release-late-sensor-probe";
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
testScript =
|
|
builtins.readFile ../shared/console.py
|
|
+ builtins.readFile ../shared/screen_recording.py
|
|
+ builtins.readFile ./check.py;
|
|
}
|