nix/nixos/common/modules/networking.nix

24 lines
446 B
Nix
Raw Normal View History

2023-12-19 08:28:59 +09:00
{lib, pkgs, config, ...}: {
2023-08-25 20:52:03 +09:00
# Enable networking with NetworkManager
2023-07-12 23:43:21 +09:00
networking = {
networkmanager = {
enable = true;
};
2023-12-19 08:28:59 +09:00
useDHCP = lib.mkDefault true;
2024-03-20 22:59:42 +09:00
enableIPv6 = lib.mkForce false;
firewall = {
enable = true;
allowedTCPPorts = [ ];
allowedUDPPorts = [ ];
};
};
2024-03-21 08:10:29 +09:00
boot.kernel.sysctl = {
"net.ipv6.conf.all.disable_ipv6" = true;
};
boot.kernelParams = [ "ipv6.disable=1" ];
2024-03-20 22:59:42 +09:00
}