From 8dc4f2c3bee30b079c82cce6ddc9f8df6d61ef91 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 4 Oct 2012 15:27:31 -0400 Subject: [PATCH] Fix the rogue service for systemd --- modules/services/misc/rogue.nix | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/modules/services/misc/rogue.nix b/modules/services/misc/rogue.nix index c313de956fc..059b39cad5e 100644 --- a/modules/services/misc/rogue.nix +++ b/modules/services/misc/rogue.nix @@ -40,14 +40,17 @@ in boot.extraTTYs = [ cfg.tty ]; - jobs.rogue = + boot.systemd.services.rogue = { description = "Rogue dungeon crawling game"; - - startOn = "started udev"; - - extraConfig = "chdir /root"; - - exec = "${pkgs.rogue}/bin/rogue < /dev/${cfg.tty} > /dev/${cfg.tty} 2>&1"; + wantedBy = [ "multi-user.target" ]; + serviceConfig = + { ExecStart = "${pkgs.rogue}/bin/rogue"; + StandardInput = "tty"; + StandardOutput = "tty"; + TTYPath = "/dev/${cfg.tty}"; + TTYReset = true; + TTYVTDisallocate = true; + }; }; services.ttyBackgrounds.specificThemes = singleton