configure hostapds in gateway profile

gateway-profile
Daniel Barlow 2024-03-18 19:52:37 +00:00
parent 0b61c0b318
commit 5dd595a209
2 changed files with 21 additions and 29 deletions

View File

@ -18,11 +18,6 @@ let
wirelessConfig = {
country_code = "GB";
inherit (secrets) wpa_passphrase;
auth_algs = 1; # 1=wpa2, 2=wep, 3=both
wpa = 2; # 1=wpa, 2=wpa2, 3=both
wpa_key_mgmt = "WPA-PSK";
wpa_pairwise = "TKIP CCMP"; # auth for wpa (may not need this?)
rsn_pairwise = "CCMP"; # auth for wpa2
wmm_enabled = 1;
};
@ -57,20 +52,16 @@ in rec {
family = "inet"; address ="${secrets.lan.prefix}.1"; prefixLength = 24;
};
};
};
services.hostap = svc.hostapd.build {
wireless.networks = {
telent = {
interface = config.hardware.networkInterfaces.wlan;
params = {
ssid = secrets.ssid;
hw_mode="g";
channel = "2";
ieee80211n = 1;
} // wirelessConfig;
};
services.hostap5 = svc.hostapd.build {
telent5 = rec {
interface = config.hardware.networkInterfaces.wlan5;
params = rec {
ssid = "${secrets.ssid}5";
hw_mode="a";
channel = 36;
@ -81,6 +72,7 @@ in rec {
ieee80211ac = 1;
} // wirelessConfig;
};
};
services.ntp = svc.ntp.build {
pools = { "pool.ntp.org" = ["iburst"]; };

View File

@ -52,7 +52,7 @@ in {
../bridge
../ntp
../ssh
# { config.services = hostaps; }
{ config.services = hostaps; }
];