2023-06-06 15:01:28 +00:00
|
|
|
# networking.nix
|
|
|
|
|
|
|
|
# Import the necessary modules
|
|
|
|
{ config, pkgs, ... }:
|
|
|
|
|
|
|
|
{
|
|
|
|
# Set the network interface configuration
|
|
|
|
# networking.interfaces.eth0.useDHCP = true;
|
|
|
|
|
|
|
|
networking.networkmanager.enable = true;
|
|
|
|
|
|
|
|
# Open ports in the firewall.
|
2023-06-11 15:31:45 +00:00
|
|
|
# networking.firewall.allowedTCPPorts = [ 22 ];
|
2023-06-06 15:01:28 +00:00
|
|
|
# networking.firewall.allowedUDPPorts = [ ... ];
|
|
|
|
# Or disable the firewall altogether.
|
2023-06-11 15:31:45 +00:00
|
|
|
networking.firewall.enable = false;
|
2023-06-06 15:01:28 +00:00
|
|
|
|
|
|
|
|
|
|
|
# Set the hostname
|
2023-06-13 14:12:52 +00:00
|
|
|
networking.hostName = "pc-mans";
|
2023-06-06 15:01:28 +00:00
|
|
|
}
|