nixos/jira: replace deprecated usage of PermissionsStartOnly
see https://github.com/NixOS/nixpkgs/issues/53852
This commit is contained in:
parent
65f449fe33
commit
114bd801f4
1 changed files with 11 additions and 7 deletions
|
@ -155,6 +155,17 @@ in
|
|||
|
||||
users.groups."${cfg.group}" = {};
|
||||
|
||||
systemd.tmpfiles.rules = [
|
||||
"d '${cfg.home}' - ${cfg.user} - - -"
|
||||
"d /run/atlassian-jira - - - - -"
|
||||
|
||||
"L+ /run/atlassian-jira/home - - - - ${cfg.home}"
|
||||
"L+ /run/atlassian-jira/logs - - - - ${cfg.home}/logs"
|
||||
"L+ /run/atlassian-jira/work - - - - ${cfg.home}/work"
|
||||
"L+ /run/atlassian-jira/temp - - - - ${cfg.home}/temp"
|
||||
"L+ /run/atlassian-jira/server.xml - - - - ${cfg.home}/server.xml"
|
||||
];
|
||||
|
||||
systemd.services.atlassian-jira = {
|
||||
description = "Atlassian JIRA";
|
||||
|
||||
|
@ -174,12 +185,6 @@ in
|
|||
preStart = ''
|
||||
mkdir -p ${cfg.home}/{logs,work,temp,deploy}
|
||||
|
||||
mkdir -p /run/atlassian-jira
|
||||
ln -sf ${cfg.home}/{logs,work,temp,server.xml} /run/atlassian-jira
|
||||
ln -sf ${cfg.home} /run/atlassian-jira/home
|
||||
|
||||
chown ${cfg.user} ${cfg.home}
|
||||
|
||||
sed -e 's,port="8080",port="${toString cfg.listenPort}" address="${cfg.listenAddress}",' \
|
||||
'' + (lib.optionalString cfg.proxy.enable ''
|
||||
-e 's,protocol="HTTP/1.1",protocol="HTTP/1.1" proxyName="${cfg.proxy.name}" proxyPort="${toString cfg.proxy.port}" scheme="${cfg.proxy.scheme}" secure="${toString cfg.proxy.secure}",' \
|
||||
|
@ -191,7 +196,6 @@ in
|
|||
User = cfg.user;
|
||||
Group = cfg.group;
|
||||
PrivateTmp = true;
|
||||
PermissionsStartOnly = true;
|
||||
ExecStart = "${pkg}/bin/start-jira.sh -fg";
|
||||
ExecStop = "${pkg}/bin/stop-jira.sh";
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue