Refactor flake patching/recursion

Signed-off-by: Nikolaos Karaolidis <nick@karaolidis.com>
This commit is contained in:
2025-07-19 12:51:28 +01:00
parent a3d44b8b26
commit 1587967488
55 changed files with 303 additions and 426 deletions

View File

@@ -24,8 +24,9 @@ in
wireguard.interfaces.wg0 =
let
ip = "${pkgs.iproute2}/bin/ip";
table = "wireguard";
in
rec {
{
ips = [
"10.0.0.2/24"
"${jupiterPublicIPv4}/32"
@@ -33,7 +34,7 @@ in
privateKeyFile = config.sops.secrets."wireguard/client/vps".path;
table = "wireguard";
inherit table;
postSetup = [ "${ip} rule add from ${jupiterPublicIPv4} table ${table}" ];
postShutdown = [ "${ip} rule del from ${jupiterPublicIPv4} table ${table}" ];