aboutsummaryrefslogtreecommitdiff
path: root/nixos/modules
diff options
context:
space:
mode:
authorKarel Kočí <cynerd@email.cz>2023-01-18 22:54:54 +0100
committerKarel Kočí <cynerd@email.cz>2023-01-18 22:54:54 +0100
commitb7dd9f396326ab914897900fbaa1e16a46928adf (patch)
treec1e43b246834910a7c3a4bf926b2621543dba843 /nixos/modules
parent79ab172cbeb4f06606ccfc486d24a0b500c72b3c (diff)
downloadnixos-personal-b7dd9f396326ab914897900fbaa1e16a46928adf.tar.gz
nixos-personal-b7dd9f396326ab914897900fbaa1e16a46928adf.tar.bz2
nixos-personal-b7dd9f396326ab914897900fbaa1e16a46928adf.zip
nioxos: 5GHz Wi-Fi
Diffstat (limited to 'nixos/modules')
-rw-r--r--nixos/modules/router.nix20
1 files changed, 10 insertions, 10 deletions
diff --git a/nixos/modules/router.nix b/nixos/modules/router.nix
index cd7841e..e149633 100644
--- a/nixos/modules/router.nix
+++ b/nixos/modules/router.nix
@@ -47,15 +47,14 @@ in {
config = mkIf cnf.enable {
networking = {
- interfaces."${cnf.brlan}" = {
- ipv4.addresses = [
- {
- address = cnf.lanIP;
- prefixLength = cnf.lanPrefix;
- }
- ];
- };
+ interfaces."${cnf.brlan}".ipv4.addresses = [
+ {
+ address = cnf.lanIP;
+ prefixLength = cnf.lanPrefix;
+ }
+ ];
nat = {
+ enable = true;
externalInterface = cnf.wan;
internalInterfaces = [cnf.brlan];
};
@@ -68,7 +67,7 @@ in {
authoritative = true;
interfaces = [cnf.brlan];
extraConfig = ''
- option domain-name-servers 1.1.1.1 8.8.8.8;
+ option domain-name-servers 1.1.1.1, 8.8.8.8;
subnet ${ipv4.prefix2ip cnf.lanIP cnf.lanPrefix} netmask ${ipv4.prefix2netmask cnf.lanPrefix} {
range ${
ipv4.ipAdd cnf.lanIP cnf.lanPrefix cnf.dynIPStart
@@ -83,7 +82,8 @@ in {
};
services.dhcpd6 = {
- enable = true;
+ # TODO
+ enable = false;
authoritative = true;
interfaces = [cnf.brlan];
extraConfig = ''