netboot: init
This commit is contained in:
parent
bde21798b5
commit
7c0205f47e
|
@ -52,6 +52,9 @@ in
|
||||||
option domain-name-servers 172.20.73.8, 9.9.9.9;
|
option domain-name-servers 172.20.73.8, 9.9.9.9;
|
||||||
ddns-domainname "${domainName}";
|
ddns-domainname "${domainName}";
|
||||||
|
|
||||||
|
next-server "${config.site.net.serv.hosts4.netboot}";
|
||||||
|
filename "netboot.xyz.kpxe";
|
||||||
|
|
||||||
subnet ${subnet4Net} netmask ${lib.netmasks.${toString subnet4Len}} {
|
subnet ${subnet4Net} netmask ${lib.netmasks.${toString subnet4Len}} {
|
||||||
range ${dhcp.start} ${dhcp.end};
|
range ${dhcp.start} ${dhcp.end};
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,17 @@
|
||||||
|
{ lib, pkgs, ... }:
|
||||||
|
let
|
||||||
|
netboot_xyz = pkgs.fetchurl {
|
||||||
|
url = "https://github.com/netbootxyz/netboot.xyz/releases/download/2.0.40/netboot.xyz.kpxe";
|
||||||
|
sha256 = "1crkr995i1hv3q548gx2xan1ymxmzcnr7mxaf77s2410mpqfcx82";
|
||||||
|
};
|
||||||
|
tftpRoot = pkgs.runCommand "tftproot" {} ''
|
||||||
|
mkdir -p $out
|
||||||
|
ln -s ${netboot_xyz} $out/netboot.xyz.kpxe
|
||||||
|
'';
|
||||||
|
in
|
||||||
|
{
|
||||||
|
services.tftpd = {
|
||||||
|
enable = true;
|
||||||
|
path = tftpRoot;
|
||||||
|
};
|
||||||
|
}
|
|
@ -40,5 +40,8 @@ in {
|
||||||
] ++
|
] ++
|
||||||
optionals (hostName == "mgmt-gw") [
|
optionals (hostName == "mgmt-gw") [
|
||||||
./container/mgmt-gw.nix
|
./container/mgmt-gw.nix
|
||||||
|
] ++
|
||||||
|
optionals (hostName == "netboot") [
|
||||||
|
./container/netboot.nix
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -214,6 +214,7 @@ hosts-inet:
|
||||||
leonos: 172.20.73.47
|
leonos: 172.20.73.47
|
||||||
minetest: 172.20.73.48
|
minetest: 172.20.73.48
|
||||||
hydra: 172.20.73.49
|
hydra: 172.20.73.49
|
||||||
|
netboot: 172.20.73.50
|
||||||
|
|
||||||
# TODO: generate from subnets
|
# TODO: generate from subnets
|
||||||
priv1:
|
priv1:
|
||||||
|
@ -463,6 +464,7 @@ hosts-inet6:
|
||||||
stats: fd23:42:c3d2:582:2:0:0:3
|
stats: fd23:42:c3d2:582:2:0:0:3
|
||||||
radius: fd23:42:c3d2:582:2:0:0:4
|
radius: fd23:42:c3d2:582:2:0:0:4
|
||||||
zeit: fd23:42:c3d2:582:2:0:0:5
|
zeit: fd23:42:c3d2:582:2:0:0:5
|
||||||
|
netboot: fd23:42:c3d2:582:2:0:0:6
|
||||||
dnscache: fd23:42:c3d2:582:f096:dbff:fee8:427d
|
dnscache: fd23:42:c3d2:582:f096:dbff:fee8:427d
|
||||||
minetest: fd23:42:c3d2:582:c3a:42ff:fe5d:b20c
|
minetest: fd23:42:c3d2:582:c3a:42ff:fe5d:b20c
|
||||||
hydra: fd23:42:c3d2:582:e03c:d7ff:fe8e:fe16
|
hydra: fd23:42:c3d2:582:e03c:d7ff:fe8e:fe16
|
||||||
|
@ -635,6 +637,7 @@ hosts-inet6:
|
||||||
stats: 2a00:8180:2c00:282:2:0:0:3
|
stats: 2a00:8180:2c00:282:2:0:0:3
|
||||||
radius: 2a00:8180:2c00:282:2:0:0:4
|
radius: 2a00:8180:2c00:282:2:0:0:4
|
||||||
zeit: 2a00:8180:2c00:282:2:0:0:5
|
zeit: 2a00:8180:2c00:282:2:0:0:5
|
||||||
|
netboot: 2a00:8180:2c00:282:2:0:0:3
|
||||||
dnscache: 2a00:8180:2c00:282:f096:dbff:fee8:427d
|
dnscache: 2a00:8180:2c00:282:f096:dbff:fee8:427d
|
||||||
minetest: 2a00:8180:2c00:282:c3a:42ff:fe5d:b20c
|
minetest: 2a00:8180:2c00:282:c3a:42ff:fe5d:b20c
|
||||||
hydra: 2a00:8180:2c00:282:e03c:d7ff:fe8e:fe16
|
hydra: 2a00:8180:2c00:282:e03c:d7ff:fe8e:fe16
|
||||||
|
|
|
@ -599,6 +599,14 @@ containers:
|
||||||
gw6: serv-gw
|
gw6: serv-gw
|
||||||
hwaddr: 0A:14:48:01:15:00
|
hwaddr: 0A:14:48:01:15:00
|
||||||
|
|
||||||
|
netboot:
|
||||||
|
interfaces:
|
||||||
|
serv:
|
||||||
|
type: veth
|
||||||
|
gw: serv-gw
|
||||||
|
gw6: serv-gw
|
||||||
|
hwaddr: 0A:14:48:01:15:01
|
||||||
|
|
||||||
mgmt-gw:
|
mgmt-gw:
|
||||||
interfaces:
|
interfaces:
|
||||||
core:
|
core:
|
||||||
|
|
Loading…
Reference in New Issue