diff options
author | lassulus <github@lassul.us> | 2024-04-03 21:05:22 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-03 21:05:22 +0200 |
commit | a41e12cc9de23baf4c8ae8f6b22e659a2515f861 (patch) | |
tree | 608acd2e591374d171f2bde92c68f05ca063aa5a /nixos/modules/services/games | |
parent | bf64d6037eb340243a05d7f14ef3de018f894af9 (diff) | |
parent | 016340590ba125356f60484550496088c569ccc7 (diff) |
Merge pull request #286356 from Stunkymonkey/terraria-umask-group
nixos/terraria: prefer 'serviceConfig' over 'chmod/chgrp'
Diffstat (limited to 'nixos/modules/services/games')
-rw-r--r-- | nixos/modules/services/games/terraria.nix | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/nixos/modules/services/games/terraria.nix b/nixos/modules/services/games/terraria.nix index ccdd779165b8..0b85f14aaf43 100644 --- a/nixos/modules/services/games/terraria.nix +++ b/nixos/modules/services/games/terraria.nix @@ -148,16 +148,13 @@ in serviceConfig = { User = "terraria"; + Group = "terraria"; Type = "forking"; GuessMainPID = true; + UMask = 007; ExecStart = "${getBin pkgs.tmux}/bin/tmux -S ${cfg.dataDir}/terraria.sock new -d ${pkgs.terraria-server}/bin/TerrariaServer ${concatStringsSep " " flags}"; ExecStop = "${stopScript} $MAINPID"; }; - - postStart = '' - ${pkgs.coreutils}/bin/chmod 660 ${cfg.dataDir}/terraria.sock - ${pkgs.coreutils}/bin/chgrp terraria ${cfg.dataDir}/terraria.sock - ''; }; networking.firewall = mkIf cfg.openFirewall { |