summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2026-12-03 01:00:45 +0000
committertv <tv@krebsco.de>2026-12-03 01:00:45 +0000
commitef189d1e7774a4bdc67c9fd09893e64af23894b1 (patch)
tree8cdec48faebe5a073d9b8a6588067b6a9410a486
parentd0a149fbe1984b6bbccf0c12cd67faa4d3e50519 (diff)
wiregrill: forward on the hub, for both families
ne set IPv4 forwarding itself; IPv6 forwarding came from tv's dirt.
-rw-r--r--configs/wiregrill.nix5
-rw-r--r--systems/ne/config.nix1
2 files changed, 5 insertions, 1 deletions
diff --git a/configs/wiregrill.nix b/configs/wiregrill.nix
index b8d23f49..baa9f3d8 100644
--- a/configs/wiregrill.nix
+++ b/configs/wiregrill.nix
@@ -25,6 +25,11 @@
in
lib.mkIf cfg.enable (lib.mkMerge [
{
+ # The hub passes packets between the other hosts.
+ boot.kernel.sysctl = lib.mkIf isHub {
+ "net.ipv4.ip_forward" = lib.mkDefault true;
+ "net.ipv6.conf.all.forwarding" = lib.mkDefault true;
+ };
networking.wireguard.interfaces.wiregrill = {
ips =
lib.optional (cfg.net.ip4 != null) (toCidrNotation cfg.net.ip4) ++
diff --git a/systems/ne/config.nix b/systems/ne/config.nix
index 13c5894c..38dab010 100644
--- a/systems/ne/config.nix
+++ b/systems/ne/config.nix
@@ -100,7 +100,6 @@
imports = [
../../configs/wiregrill.nix
];
- boot.kernel.sysctl."net.ipv4.ip_forward" = 1;
tv.iptables.extra4.nat.POSTROUTING = [ "-s 10.244.3.0/24 ! -d 10.244.3.0/24 -j MASQUERADE" ];
tv.iptables.extra6.nat.POSTROUTING = [ "-s 42:1::/32 ! -d 42:1::/32 -j MASQUERADE" ];
tv.iptables.extra6.filter.FORWARD = [
[cgit] Unable to lock slot /tmp/cgit/d4200000.lock: Permission denied (13)