static ip

This commit is contained in:
death916 2025-06-15 05:24:52 -07:00
parent 550afaf831
commit f852d6a962

View file

@ -77,9 +77,21 @@
networking.bridges.br0.interfaces = [ "enp41s0" ];
networking.interfaces.br0 = {
useDHCP = true;
ipv4.addresses = [
{
address = "192.168.0.116"; # <-- SET YOUR SERVER'S DESIRED STATIC IP
prefixLength = 24; # <-- SET YOUR SUBNET MASK (24 = 255.255.255.0)
}
];
};
networking.defaultGateway = "192.168.1.1"; # <-- SET YOUR ROUTER'S IP
networking.nameservers = [
"1.1.1.1", # <-- SET YOUR PREFERRED DNS
"8.8.8.8"
];
networking.interfaces.enp41s0.useDHCP = false;
# Allow SSH