unl0kr: dont run atop getty -- just a bare /dev/tty1
i'm not sure what agetty was ever doing here. unl0kr itself runs fine, it launches ~/.profile, and if i interrupt ~/.profile to use a console, that works too. the console does regularly get interrupted by systemd output, but i've checked and the agetty method had that same program.
This commit is contained in:
@@ -134,16 +134,14 @@ in
|
|||||||
# prevent nixos-rebuild from killing us after a redeploy
|
# prevent nixos-rebuild from killing us after a redeploy
|
||||||
services."autovt@${tty}".enable = false;
|
services."autovt@${tty}".enable = false;
|
||||||
services.unl0kr = {
|
services.unl0kr = {
|
||||||
# --skip-login is funny here: it *doesn't* skip the login; rather it has getty not try to read the username for itself
|
serviceConfig.ExecStart = "${cfg.config.launcher}/bin/unl0kr-login";
|
||||||
# and instead launch --login-program *immediately*
|
|
||||||
# N.B.: exec paths here must be absolute. neither systemd nor agetty query PATH.
|
|
||||||
serviceConfig.ExecStart = "${pkgs.util-linux}/bin/agetty --login-program '${cfg.config.launcher}/bin/unl0kr-login' --noclear --skip-login --keep-baud ${tty} 115200,38400,9600 $TERM";
|
|
||||||
|
|
||||||
serviceConfig.Type = "simple";
|
serviceConfig.Type = "simple";
|
||||||
serviceConfig.Restart = "always";
|
serviceConfig.Restart = "always";
|
||||||
serviceConfig.RestartSec = "5";
|
serviceConfig.RestartSec = "5";
|
||||||
# XXX: unsure which of these are necessary nor what they do.
|
# XXX: unsure which of these are necessary nor what they do.
|
||||||
# copied from greetd and agetty services.
|
# copied from greetd and agetty services.
|
||||||
|
# serviceConfig.{TTYPath,StandardInput,StandardOutput} connects the corresponding tty to the service's stdin/stdout.
|
||||||
serviceConfig.TTYPath = "/dev/${tty}";
|
serviceConfig.TTYPath = "/dev/${tty}";
|
||||||
serviceConfig.TTYReset = "yes";
|
serviceConfig.TTYReset = "yes";
|
||||||
serviceConfig.StandardInput = "tty";
|
serviceConfig.StandardInput = "tty";
|
||||||
|
Reference in New Issue
Block a user