clerie
6840548833
Advertise current prefixes more often than claimed addresses expire. Also increased lifetimes for claimed addresses.
70 lines
1.4 KiB
Nix
70 lines
1.4 KiB
Nix
{ ... }:
|
|
|
|
{
|
|
|
|
## Heimnetz
|
|
networking.vlans."enp1s0.201" = {
|
|
id = 201;
|
|
interface = "enp1s0";
|
|
};
|
|
networking.bridges."net-heimnetz".interfaces = [
|
|
"enp1s0.201"
|
|
"enp2s0"
|
|
];
|
|
networking.interfaces."net-heimnetz".ipv6.addresses = [
|
|
{ address = "fe80::1"; prefixLength = 64; }
|
|
{ address = "fd00:152:152:4::1"; prefixLength = 64; }
|
|
];
|
|
networking.interfaces."net-heimnetz".ipv4.addresses = [
|
|
{ address = "10.152.4.1"; prefixLength = 24; }
|
|
];
|
|
|
|
services.radvd.config = ''
|
|
interface net-heimnetz {
|
|
AdvSendAdvert on;
|
|
MaxRtrAdvInterval 30;
|
|
prefix ::/64 {
|
|
AdvValidLifetime 300;
|
|
AdvPreferredLifetime 120;
|
|
};
|
|
RDNSS fd00:152:152::1 {};
|
|
DNSSL net.clerie.de {};
|
|
};
|
|
'';
|
|
|
|
services.kea.dhcp4 = {
|
|
settings = {
|
|
interfaces-config = {
|
|
interfaces = [ "net-heimnetz" ];
|
|
};
|
|
subnet4 = [
|
|
# Heimnetz
|
|
{
|
|
id = 201;
|
|
subnet = "10.152.4.0/24";
|
|
pools = [
|
|
{
|
|
pool = "10.152.4.100 - 10.152.4.240";
|
|
}
|
|
];
|
|
option-data = [
|
|
{
|
|
name = "routers";
|
|
data = "10.152.4.1";
|
|
}
|
|
{
|
|
name = "domain-name-servers";
|
|
data = "10.152.0.1";
|
|
}
|
|
{
|
|
name = "domain-name";
|
|
data = "net.clerie.de";
|
|
}
|
|
];
|
|
}
|
|
];
|
|
};
|
|
};
|
|
|
|
}
|