From 2b2077d46a5e67416ee5bce3480e85e4edc31de0 Mon Sep 17 00:00:00 2001 From: nyanloutre Date: Thu, 22 Feb 2024 11:10:45 +0100 Subject: [PATCH 1/2] fix server access when fiber down --- systems/LoutreOS/configuration.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/systems/LoutreOS/configuration.nix b/systems/LoutreOS/configuration.nix index bf95a80..e9de815 100644 --- a/systems/LoutreOS/configuration.nix +++ b/systems/LoutreOS/configuration.nix @@ -111,6 +111,10 @@ ip6tables -A loutreos-forward -j ACCEPT -i eno2 ip6tables -A loutreos-forward -j nixos-fw-log-refuse ip6tables -w -A FORWARD -j loutreos-forward + + # Redirect local network request from server external IP to internal IP + # Make the server available even without internet access + iptables -t nat -A PREROUTING -s 10.30.0.0/16 -d 176.180.172.105 -j DNAT --to 10.30.0.1 ''; }; }; From d1b5f85fb3288fde993668721dd3367b5931294e Mon Sep 17 00:00:00 2001 From: nyanloutre Date: Thu, 22 Feb 2024 11:11:06 +0100 Subject: [PATCH 2/2] fix rspam WebUI with IPv6 --- systems/LoutreOS/services.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/systems/LoutreOS/services.nix b/systems/LoutreOS/services.nix index 81f4f91..49d6c10 100644 --- a/systems/LoutreOS/services.nix +++ b/systems/LoutreOS/services.nix @@ -87,7 +87,7 @@ in }; rspamd.workers.controller.extraConfig = '' - secure_ip = ["0.0.0.0/0"]; + secure_ip = ["0.0.0.0/0", "::"]; ''; # redis.enable = true;