23 lines
470 B
Nix
23 lines
470 B
Nix
{ config, pkgs, ... }:
|
|
|
|
{
|
|
# Allow ipv4 port forwarding
|
|
boot.kernel.sysctl = { "net.ipv4.ip_forward" = 1; };
|
|
|
|
networking = {
|
|
|
|
useDHCP = false;
|
|
interfaces.eth0.useDHCP = false;
|
|
interfaces.wlan0.useDHCP = true;
|
|
|
|
interfaces.eth0.ipv4.addresses = [ {
|
|
address = "192.168.22.1";
|
|
prefixLength = 24;
|
|
} ];
|
|
|
|
# WPA2 pasks are kept secret in /etc/wpa_supplicant.conf
|
|
wireless.enable = true;
|
|
wireless.interfaces = [ "wlan0" ];
|
|
};
|
|
}
|