Compare commits

..

No commits in common. "59435f987b0e78706c2735230168d7454d4da6e5" and "268dbf181ab5aa27d49bb43eb79b4d4da9941b70" have entirely different histories.

View File

@ -2,12 +2,7 @@
{ {
boot = { boot = {
kernel.sysctl = { kernel.sysctl."net.ipv6.conf.all.forwarding" = true;
"net.ipv6.conf.all.forwarding" = true;
"net.ipv6.conf.default.forwarding" = true;
"net.ipv4.conf.all.forwarding" = true;
"net.ipv4.conf.default.forwarding" = true;
};
}; };
# Enable LTE drivers # Enable LTE drivers
@ -151,13 +146,13 @@
# 0: from all lookup local # 0: from all lookup local
# 60: from all iif lo dport 25 lookup vpn # mails are forced to vpn table # 60: from all iif lo dport 25 lookup vpn # mails are forced to vpn table
# 4000: from all fwmark 0x1 lookup fiber # fwmark indicate established connection that must go through same interface
# 5000: from all fwmark 0x2 lookup lte
# 6000: from all fwmark 0x3 lookup vpn
# 32766: from all lookup main # main table should contain no default routes, only local network routes # 32766: from all lookup main # main table should contain no default routes, only local network routes
# 32767: from all lookup default # 32767: from all lookup default
# 41000: from all fwmark 0x1 lookup fiber # fwmark indicate established connection that must go through same interface # 40000: from all lookup fiber # first table encountered with a default route if fiber is up
# 42000: from all fwmark 0x2 lookup lte # 50000: from all lookup lte # first table encountered with a default route if fiber is down
# 43000: from all fwmark 0x3 lookup vpn
# 51000: from all lookup fiber # first table encountered with a default route if fiber is up
# 52000: from all lookup lte # first table encountered with a default route if fiber is down
systemd.network = let systemd.network = let
routeTables = { routeTables = {
@ -238,14 +233,14 @@
routingPolicyRuleConfig = { routingPolicyRuleConfig = {
FirewallMark = 1; FirewallMark = 1;
Table = routeTables.fiber; Table = routeTables.fiber;
Priority = 41000; Priority = 4000;
Family = "both"; Family = "both";
}; };
} }
{ {
routingPolicyRuleConfig = { routingPolicyRuleConfig = {
Table = routeTables.fiber; Table = routeTables.fiber;
Priority = 51000; Priority = 40000;
Family = "both"; Family = "both";
}; };
} }
@ -269,14 +264,14 @@
routingPolicyRuleConfig = { routingPolicyRuleConfig = {
FirewallMark = 2; FirewallMark = 2;
Table = routeTables.lte; Table = routeTables.lte;
Priority = 42000; Priority = 5000;
Family = "both"; Family = "both";
}; };
} }
{ {
routingPolicyRuleConfig = { routingPolicyRuleConfig = {
Table = routeTables.lte; Table = routeTables.lte;
Priority = 52000; Priority = 50000;
Family = "both"; Family = "both";
}; };
} }
@ -311,7 +306,7 @@
routingPolicyRuleConfig = { routingPolicyRuleConfig = {
FirewallMark = 3; FirewallMark = 3;
Table = routeTables.vpn; Table = routeTables.vpn;
Priority = 43000; Priority = 6000;
Family = "both"; Family = "both";
}; };
} }