Wrap the networking_local.nix, because of the error.
This commit is contained in:
parent
598f9bb256
commit
25b834e413
1 changed files with 34 additions and 32 deletions
|
|
@ -4,42 +4,44 @@
|
||||||
lib,
|
lib,
|
||||||
...
|
...
|
||||||
}: {
|
}: {
|
||||||
# Some programs need SUID wrappers, can be configured further or are
|
config = {
|
||||||
# started in user sessions.
|
# Some programs need SUID wrappers, can be configured further or are
|
||||||
# programs.mtr.enable = true;
|
# started in user sessions.
|
||||||
# programs.gnupg.agent = {
|
# programs.mtr.enable = true;
|
||||||
# enable = true;
|
# programs.gnupg.agent = {
|
||||||
# enableSSHSupport = true;
|
# enable = true;
|
||||||
# };
|
# enableSSHSupport = true;
|
||||||
|
# };
|
||||||
|
|
||||||
# List services that you want to enable:
|
# List services that you want to enable:
|
||||||
|
|
||||||
# Open ports in the firewall.
|
# Open ports in the firewall.
|
||||||
# networking.firewall.allowedTCPPorts = [ ... ];
|
# networking.firewall.allowedTCPPorts = [ ... ];
|
||||||
# networking.firewall.allowedUDPPorts = [ ... ];
|
# networking.firewall.allowedUDPPorts = [ ... ];
|
||||||
# Or disable the firewall altogether.
|
# Or disable the firewall altogether.
|
||||||
# networking.firewall.enable = false;
|
# networking.firewall.enable = false;
|
||||||
|
|
||||||
services.resolved.enable = false;
|
services.resolved.enable = false;
|
||||||
|
|
||||||
# Use this clean static network configuration instead:
|
# Use this clean static network configuration instead:
|
||||||
networking.useDHCP = false;
|
networking.useDHCP = false;
|
||||||
networking.networkmanager.enable = false; # Disable NetworkManager
|
networking.networkmanager.enable = false; # Disable NetworkManager
|
||||||
|
|
||||||
networking.interfaces.ens18 = {
|
networking.interfaces.ens18 = {
|
||||||
ipv4.addresses = [
|
ipv4.addresses = [
|
||||||
{
|
{
|
||||||
address = config.local.address or "10.1.1.100";
|
address = config.local.address or "10.1.1.100";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
networking.defaultGateway = {
|
||||||
|
address = "10.1.1.1";
|
||||||
|
interface = "ens18";
|
||||||
|
};
|
||||||
|
|
||||||
|
# Explicitly set DNS
|
||||||
|
networking.nameservers = ["10.1.1.2"]; # PiHole DNS
|
||||||
};
|
};
|
||||||
|
|
||||||
networking.defaultGateway = {
|
|
||||||
address = "10.1.1.1";
|
|
||||||
interface = "ens18";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Explicitly set DNS
|
|
||||||
networking.nameservers = ["10.1.1.2"]; # PiHole DNS
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue