Merge pull request #45811 from Nadrieril/fix-usbguard-auditfile

nixos/usbguard: ensure the audit log file can be created 
nixos/usbguard: disable debug output
This commit is contained in:
Sarah Brofeldt 2018-08-31 11:40:13 +02:00 committed by GitHub
commit bb321a2624
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -188,11 +188,14 @@ in {
wants = [ "systemd-udevd.service" "local-fs.target" ];
# make sure an empty rule file and required directories exist
preStart = ''mkdir -p $(dirname "${cfg.ruleFile}") "${cfg.IPCAccessControlFiles}" && ([ -f "${cfg.ruleFile}" ] || touch ${cfg.ruleFile})'';
preStart = ''
mkdir -p $(dirname "${cfg.ruleFile}") $(dirname "${cfg.auditFilePath}") "${cfg.IPCAccessControlFiles}" \
&& ([ -f "${cfg.ruleFile}" ] || touch ${cfg.ruleFile})
'';
serviceConfig = {
Type = "simple";
ExecStart = ''${pkgs.usbguard}/bin/usbguard-daemon -P -d -k -c ${daemonConfFile}'';
ExecStart = ''${pkgs.usbguard}/bin/usbguard-daemon -P -k -c ${daemonConfFile}'';
Restart = "on-failure";
};
};