This commit is contained in:
iFargle 2023-10-08 13:39:34 +09:00
parent 92a489bf42
commit df065ba7f6

View file

@ -63,10 +63,10 @@
enable = true; enable = true;
internalInterfaces = [ "wireguard0" ]; internalInterfaces = [ "wireguard0" ];
externalInterface = "eno3"; externalInterface = "eno3";
extraCommands = ''iptables -t nat -A nixos-nat-post -d 10.100.0.2 --dport 80 -j SNAT --to-source 10.100.0.1''; extraCommands = ''${pkgs.iptables}/bin/iptables -t nat -A nixos-nat-post -d 10.100.0.2 --dport 80 -j SNAT --to-source 10.100.0.1'';
forwardPorts = [ forwardPorts = [
{ sourcePort = 80; destination = "10.100.0.2:80"; } { sourcePort = 80; destination = "10.100.0.2"; }
{ sourcePort = 443; destination = "10.100.0.2:443"; } { sourcePort = 443; destination = "10.100.0.2"; }
]; ];
}; };
} }