mirror of
https://github.com/Death916/nixconfig.git
synced 2026-04-11 04:48:25 -07:00
static ip
This commit is contained in:
parent
550afaf831
commit
f852d6a962
1 changed files with 13 additions and 1 deletions
|
|
@ -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
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue