nixos/apache-kafka: replace deprecated usage of PermissionsStartOnly
see https://github.com/NixOS/nixpkgs/issues/53852
This commit is contained in:
parent
2c350782ba
commit
b6bfb874ec
@ -131,6 +131,8 @@ in {
|
|||||||
home = head cfg.logDirs;
|
home = head cfg.logDirs;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
systemd.tmpfiles.rules = map (logDir: "d '${logDir} 0700 apache-kafka - - -") cfg.logDirs;
|
||||||
|
|
||||||
systemd.services.apache-kafka = {
|
systemd.services.apache-kafka = {
|
||||||
description = "Apache Kafka Daemon";
|
description = "Apache Kafka Daemon";
|
||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = [ "multi-user.target" ];
|
||||||
@ -145,15 +147,8 @@ in {
|
|||||||
${serverConfig}
|
${serverConfig}
|
||||||
'';
|
'';
|
||||||
User = "apache-kafka";
|
User = "apache-kafka";
|
||||||
PermissionsStartOnly = true;
|
|
||||||
SuccessExitStatus = "0 143";
|
SuccessExitStatus = "0 143";
|
||||||
};
|
};
|
||||||
preStart = ''
|
|
||||||
mkdir -m 0700 -p ${concatStringsSep " " cfg.logDirs}
|
|
||||||
if [ "$(id -u)" = 0 ]; then
|
|
||||||
chown apache-kafka ${concatStringsSep " " cfg.logDirs};
|
|
||||||
fi
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user