Prove
This commit is contained in:
parent
4300ddacb0
commit
b80563f0ed
10 changed files with 755 additions and 1 deletions
26
lxc-nix/services/networking.nix
Normal file
26
lxc-nix/services/networking.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
{ ... }:
|
||||
{
|
||||
|
||||
networking = {
|
||||
|
||||
# If you prefer DHCP
|
||||
# interfaces.eth0.useDHCP = true;
|
||||
|
||||
# We don't use DHCP, so we configure it statically.
|
||||
interfaces.eth0.ipv4.addresses = [{
|
||||
address = "10.42.135.101";
|
||||
prefixLength = 24;
|
||||
}];
|
||||
|
||||
# We can access the internet through this interface.
|
||||
defaultGateway = {
|
||||
address = "10.42.135.1";
|
||||
interface = "eth0";
|
||||
};
|
||||
|
||||
# Since we don't use DHCP, we need to set our own nameservers.
|
||||
nameservers = [ "1.1.1.1" "1.0.0.1" ];
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue