nixos/nagios: replace deprecated usage of PermissionsStartOnly
see #53852
This commit is contained in:
parent
609c1580d8
commit
c2f8d6334c
@ -149,7 +149,6 @@ in
|
||||
description = "Nagios user ";
|
||||
uid = config.ids.uids.nagios;
|
||||
home = nagiosState;
|
||||
createHome = true;
|
||||
group = "nagios";
|
||||
};
|
||||
|
||||
@ -175,14 +174,10 @@ in
|
||||
Group = "nagios";
|
||||
Restart = "always";
|
||||
RestartSec = 2;
|
||||
PermissionsStartOnly = true;
|
||||
LogsDirectory = "nagios";
|
||||
StateDirectory = "nagios";
|
||||
};
|
||||
|
||||
preStart = ''
|
||||
mkdir -m 0755 -p ${nagiosState} ${nagiosLogDir}
|
||||
chown -R nagios:nagios ${nagiosState} ${nagiosLogDir}
|
||||
'';
|
||||
|
||||
script = ''
|
||||
for i in ${toString cfg.plugins}; do
|
||||
export PATH=$i/bin:$i/sbin:$i/libexec:$PATH
|
||||
|
Loading…
Reference in New Issue
Block a user