From d69e5e7cab94499b3528e67a3f73926167b8b76e Mon Sep 17 00:00:00 2001 From: Youwen Wu Date: Sat, 7 Sep 2024 02:40:34 -0700 Subject: [PATCH] feat: allow more ports in firewall for grim dawn --- modules/linux/networking/default.nix | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/modules/linux/networking/default.nix b/modules/linux/networking/default.nix index af5d2d3..3af770e 100755 --- a/modules/linux/networking/default.nix +++ b/modules/linux/networking/default.nix @@ -2,25 +2,32 @@ let universalAllowedPorts = [ 27016 # grim dawn 42805 # grim dawn + 42852 # grim dawn + 42872 # grim dawn + 27015 # grim dawn + 27036 # grim dawn + 5173 # vite test server 4173 # vite test server ]; - universalAllowedRanges = [ - { - from = 42852; - to = 42872; - } - ]; + universalAllowedRanges = [ ]; in { services.openssh.enable = true; + networking.firewall = { + enable = true; allowedTCPPorts = universalAllowedPorts; allowedUDPPorts = universalAllowedPorts; - allowedUDPPortRanges = universalAllowedRanges; + allowedUDPPortRanges = universalAllowedRanges ++ [ + { + from = 27031; + to = 27036; + } + ]; allowedTCPPortRanges = universalAllowedRanges; }; - networking.firewall.enable = true; + networking.nameservers = [ "1.1.1.1" "1.0.0.1"