2007-11-15 17:16:16 +00:00
|
|
|
{config, pkgs, nix, nixEnvVars}:
|
2006-12-09 03:11:14 +00:00
|
|
|
|
|
|
|
{
|
|
|
|
name = "nix-daemon";
|
|
|
|
|
|
|
|
job = "
|
|
|
|
start on startup
|
|
|
|
stop on shutdown
|
2007-02-22 18:04:18 +00:00
|
|
|
respawn
|
|
|
|
script
|
2009-02-27 13:40:31 +00:00
|
|
|
export PATH=${if config.nix.distributedBuilds then "${pkgs.openssh}/bin:${pkgs.gzip}/bin:" else ""}${pkgs.openssl}/bin:${nix}/bin:$PATH
|
2007-11-15 17:16:16 +00:00
|
|
|
${nixEnvVars}
|
2009-02-27 13:40:31 +00:00
|
|
|
exec nice -10 ${nix}/bin/nix-worker --daemon > /dev/null 2>&1
|
2007-02-22 18:04:18 +00:00
|
|
|
end script
|
2006-12-09 03:11:14 +00:00
|
|
|
";
|
|
|
|
|
|
|
|
}
|