mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-07 20:53:22 +00:00
gnustep: fix gdnc, gdomap
Both gdnc and gdomap seem to work.
This commit is contained in:
parent
d3d580ebbe
commit
697982b91b
@ -4,7 +4,6 @@ with lib;
|
|||||||
|
|
||||||
let
|
let
|
||||||
cfg = config.services.gdomap;
|
cfg = config.services.gdomap;
|
||||||
pidFile = "${cfg.pidDir}/gdomap.pid";
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
#
|
#
|
||||||
@ -20,9 +19,11 @@ in
|
|||||||
Note that gdomap runs as root.
|
Note that gdomap runs as root.
|
||||||
";
|
";
|
||||||
};
|
};
|
||||||
pidDir = mkOption {
|
|
||||||
default = "/var/run/gdomap";
|
pidfile = mkOption {
|
||||||
description = "Location of the file which stores the PID of gdomap";
|
type = types.path;
|
||||||
|
default = "/tmp/gdomap.pid";
|
||||||
|
description = "Location of the pid file for gdomap daemon";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
@ -37,15 +38,11 @@ in
|
|||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = [ "multi-user.target" ];
|
||||||
after = [ "network.target" ];
|
after = [ "network.target" ];
|
||||||
path = [ pkgs.gnustep_base ];
|
path = [ pkgs.gnustep_base ];
|
||||||
preStart = ''
|
|
||||||
mkdir -m 0700 -p ${cfg.pidDir}
|
|
||||||
chown -R nobody:nobody ${cfg.pidDir}
|
|
||||||
'';
|
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
|
PIDFile = cfg.pidfile;
|
||||||
ExecStart = "@${pkgs.gnustep_base}/bin/gdomap"
|
ExecStart = "@${pkgs.gnustep_base}/bin/gdomap"
|
||||||
+ " -d -p"
|
+ " -d -p"
|
||||||
+ " -I ${pidFile}";
|
+ " -I ${cfg.pidfile}";
|
||||||
# + " -j ${cfg.pidDir}";
|
|
||||||
Restart = "always";
|
Restart = "always";
|
||||||
RestartSec = 2;
|
RestartSec = 2;
|
||||||
TimeoutStartSec = "30";
|
TimeoutStartSec = "30";
|
||||||
@ -53,4 +50,4 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -24,12 +24,11 @@ in {
|
|||||||
requires = [ "gdomap.service" ];
|
requires = [ "gdomap.service" ];
|
||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = [ "multi-user.target" ];
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
ExecStart = ''${pkgs.gnustep_base}/bin/gdnc --verbose'';
|
ExecStart = ''${pkgs.gnustep_base}/bin/gdnc -f'';
|
||||||
Restart = "always";
|
Restart = "always";
|
||||||
RestartSec = 10;
|
RestartSec = 10;
|
||||||
TimeoutStartSec = "30";
|
TimeoutStartSec = "30";
|
||||||
Type = "simple";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user