From d7857b5dee6ec6d6bed17ada93864b4595c0ffd4 Mon Sep 17 00:00:00 2001 From: Christoph Urlacher Date: Thu, 10 Jul 2025 23:54:01 +0200 Subject: [PATCH] System/Thinknix: Update postup/postdown iptables rules for vps-wg-client --- system/thinknix/default.nix | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/system/thinknix/default.nix b/system/thinknix/default.nix index 943b42e1..9ff4bd7e 100644 --- a/system/thinknix/default.nix +++ b/system/thinknix/default.nix @@ -70,14 +70,14 @@ # ${pkgs.iproute2}/bin/ip netns add ${name} # ''; - # postSetup = '' - # ${pkgs.iptables} -A FORWARD -i wg0-client -j ACCEPT - # ${pkgs.iptables} -t nat -A POSTROUTING -o eth0 -j MASQUERADE - # ''; - # postShutdown = '' - # ${pkgs.iptables} -D FORWARD -i wg0-client -j ACCEPT - # ${pkgs.iptables} -t nat -D POSTROUTING -o eth0 -j MASQUERADE - # ''; + postSetup = '' + ${pkgs.iptables}/bin/iptables -A FORWARD -i vps-wg-client -j ACCEPT + ${pkgs.iptables}/bin/iptables -t nat -A POSTROUTING -o ens18 -j MASQUERADE + ''; + postShutdown = '' + ${pkgs.iptables}/bin/iptables -D FORWARD -i vps-wg-client -j ACCEPT + ${pkgs.iptables}/bin/iptables -t nat -D POSTROUTING -o ens18 -j MASQUERADE + ''; peers = [ {