1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2025-03-28 02:37:09 +00:00

nix-daemon: add option to configure a logfile

This commit is contained in:
Daiderd Jordan 2017-11-28 22:25:51 +01:00
parent a20e9d040c
commit 48af45075a
No known key found for this signature in database
GPG key ID: D02435D05B810C96

View file

@ -14,6 +14,18 @@ in
description = "Whether to activate system at boot time.";
};
services.nix-daemon.logFile = mkOption {
type = types.nullOr types.path;
default = null;
example = "/var/log/nix-daemon.log";
description = ''
The logfile to use for the nix-daemon service. Alternatively
<command>sudo launchctl debug system/org.nixos.nix-daemon --stderr</command>
can be used to stream the logs to a shell after restarting the service with
<command>sudo launchctl kickstart -k system/org.nixos.nix-daemon</command>.
'';
};
services.nix-daemon.tempDir = mkOption {
type = types.nullOr types.path;
default = null;
@ -38,6 +50,7 @@ in
serviceConfig.LowPriorityIO = config.nix.daemonIONice;
serviceConfig.Nice = config.nix.daemonNiceLevel;
serviceConfig.SoftResourceLimits.NumberOfFiles = 4096;
serviceConfig.StandardErrorPath = cfg.logFile;
serviceConfig.EnvironmentVariables = config.nix.envVars
// { NIX_SSL_CERT_FILE = "${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt"; }