flake cleanup and wg setup persistence

This commit is contained in:
Clara Dautermann 2025-04-06 07:50:37 +02:00
parent a1e9e81ae9
commit 0ac3bbfbe2
7 changed files with 80 additions and 32 deletions

View file

@ -35,6 +35,4 @@
};
networking.firewall.allowedTCPPorts = [ 8080 ];
}

View file

@ -9,6 +9,15 @@ in {
firewall.allowedUDPPorts = [ wg_port ];
firewall.rejectPackets = true;
firewall.trustedInterfaces = [ "wgbr" "wg0" ];
interfaces.wgbr.ipv4 = {
routes = [ ];
addresses = [
{
address = "10.8.1.1";
prefixLength = 24;
}
];
};
wg-quick.interfaces = {
wg0 = {
@ -27,7 +36,7 @@ in {
publicKey = "AJ1nr0/w8OvsNq5Ju//m4856u7yY0hlPGMEGeZtlhlY=";
# Forward all the traffic via VPN.
allowedIPs = [ "10.8.0.0/24" ];
allowedIPs = [ "10.8.0.0/16" ];
# Set this to the server IP and port.
endpoint = "202.61.230.52:51820";