diff options
author | Felix Buehler <account@buehler.rocks> | 2024-02-04 21:17:01 +0100 |
---|---|---|
committer | Felix Buehler <account@buehler.rocks> | 2024-02-04 21:27:01 +0100 |
commit | 016340590ba125356f60484550496088c569ccc7 (patch) | |
tree | 96e2586a35fb9a436724c62363e3859897f5cd5d /nixos/modules/services/games | |
parent | 237e77803ea0f34707b154dafcd2f8a47e54798f (diff) |
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 { |