From 5dd167ee5ff71b20294e78a66d374e4308f3d767 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Mon, 23 Dec 2019 16:37:47 +0100 Subject: ... --- custom/uucp.nix | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) (limited to 'custom') diff --git a/custom/uucp.nix b/custom/uucp.nix index 02c9cb87..af87231a 100644 --- a/custom/uucp.nix +++ b/custom/uucp.nix @@ -39,9 +39,6 @@ let chat = pkgs.writeScript "chat" '' #!${pkgs.stdenv.shell} - ${pkgs.utillinux}/bin/ionice -c 3 -p $$ - ${pkgs.utillinux}/bin/renice -n 15 -p $$ - echo . exec ${config.security.wrapperDir}/uucico ''; @@ -306,7 +303,21 @@ in { setgid = false; }; }; - in listToAttrs (map wrapper ["uucico" "uuxqt" "cu" "uucp" "uuname" "uustat" "uux"]); + in listToAttrs (map wrapper ["uuxqt" "cu" "uucp" "uuname" "uustat" "uux"]); + security.wrappers.uucico = { + source = pkgs.writeScript '' + #!${pkgs.stdenv.shell} + + ${pkgs.utillinux}/bin/renice -n 15 -p $$ + ${pkgs.utillinux}/bin/ionice -c 3 -p $$ + + exec ${pkgs.uucp}/bin/uucico $@ + ''; + owner = "root"; + group = "root"; + setuid = true; + setgid = false; + }; nixpkgs.overlays = [(self: super: { uucp = super.stdenv.lib.overrideDerivation super.uucp (oldAttrs: { @@ -357,8 +368,6 @@ in { User = "uucp"; Type = "oneshot"; ExecStart = "${config.security.wrapperDir}/uucico -D -S %i"; - Nice = 15; - IOSchedulingClass = "idle"; }; }; -- cgit v1.2.3