nixos/sing-box: set home and cwd to state directory (#446379)

This commit is contained in:
h7x4
2025-10-09 00:06:05 +00:00
committed by GitHub

View File

@@ -75,6 +75,7 @@ in
StateDirectoryMode = "0700";
RuntimeDirectory = "sing-box";
RuntimeDirectoryMode = "0700";
WorkingDirectory = "/var/lib/sing-box";
ExecStartPre =
let
script = pkgs.writeShellScript "sing-box-pre-start" ''
@@ -95,6 +96,7 @@ in
users.sing-box = {
isSystemUser = true;
group = "sing-box";
home = "/var/lib/sing-box";
};
groups.sing-box = { };
};