mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 05:31:22 +00:00
duplicati: PermissionsStartOnly is deprecated
This commit is contained in:
parent
c06b8b5988
commit
f572d4eb91
|
@ -47,15 +47,11 @@ in
|
|||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig = {
|
||||
User = cfg.user;
|
||||
PermissionsStartOnly = true;
|
||||
Group = "duplicati";
|
||||
StateDirectory = "/var/lib/duplicati";
|
||||
ExecStart = "${pkgs.duplicati}/bin/duplicati-server --webservice-interface=${cfg.interface} --webservice-port=${toString cfg.port} --server-datafolder=/var/lib/duplicati";
|
||||
Restart = "on-failure";
|
||||
};
|
||||
preStart = ''
|
||||
mkdir -p /var/lib/duplicati
|
||||
chown -R ${cfg.user}:duplicati /var/lib/duplicati
|
||||
'';
|
||||
};
|
||||
|
||||
users.users.duplicati = lib.optionalAttrs (cfg.user == "duplicati") {
|
||||
|
|
Loading…
Reference in a new issue