From c2cf696430055498467dd9deec59939e8d52a43e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Sun, 16 Jul 2017 18:28:02 +0100 Subject: [PATCH] nixos/agetty: override upstream default Since systemd 234 we keep default value for ExecStart in the upstream service file. Therefor we need to override it in our module. --- nixos/modules/services/ttys/agetty.nix | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/nixos/modules/services/ttys/agetty.nix b/nixos/modules/services/ttys/agetty.nix index 051d54e932fb..f8dd75ea2c46 100644 --- a/nixos/modules/services/ttys/agetty.nix +++ b/nixos/modules/services/ttys/agetty.nix @@ -68,14 +68,19 @@ in services.mingetty.greetingLine = mkDefault ''<<< Welcome to NixOS ${config.system.nixosLabel} (\m) - \l >>>''; systemd.services."getty@" = - { serviceConfig.ExecStart = gettyCmd "--noclear --keep-baud %I 115200,38400,9600 $TERM"; + { serviceConfig.ExecStart = [ + "" # override upstream default with an empty ExecStart + (gettyCmd "--noclear --keep-baud %I 115200,38400,9600 $TERM") + ]; restartIfChanged = false; }; systemd.services."serial-getty@" = - { serviceConfig.ExecStart = - let speeds = concatStringsSep "," (map toString config.services.mingetty.serialSpeed); - in gettyCmd "%I ${speeds} $TERM"; + let speeds = concatStringsSep "," (map toString config.services.mingetty.serialSpeed); in + { serviceConfig.ExecStart = [ + "" # override upstream default with an empty ExecStart + (gettyCmd "%I ${speeds} $TERM") + ]; restartIfChanged = false; };