add netboot.xyz
parent
1322814b59
commit
6466b32230
|
@ -56,6 +56,7 @@ in {
|
||||||
./checkinator-tracker.nix
|
./checkinator-tracker.nix
|
||||||
./checkinator-web.nix
|
./checkinator-web.nix
|
||||||
./mikrotik-exporter.nix
|
./mikrotik-exporter.nix
|
||||||
|
./netboot.nix
|
||||||
./laserproxy/service.nix
|
./laserproxy/service.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -188,6 +189,7 @@ in {
|
||||||
udp dport 53 accept
|
udp dport 53 accept
|
||||||
tcp dport 80 accept
|
tcp dport 80 accept
|
||||||
tcp dport 443 accept
|
tcp dport 443 accept
|
||||||
|
udp dport tftp accept
|
||||||
|
|
||||||
iifname managment udp dport tftp accept
|
iifname managment udp dport tftp accept
|
||||||
iifname lan tcp dport 8080 accept
|
iifname lan tcp dport 8080 accept
|
||||||
|
|
24
dhcpd.conf
24
dhcpd.conf
|
@ -12,25 +12,15 @@ subnet 10.8.0.0 netmask 255.255.0.0 {
|
||||||
range 10.8.0.20 10.8.0.199;
|
range 10.8.0.20 10.8.0.199;
|
||||||
authoritative;
|
authoritative;
|
||||||
allow bootp;
|
allow bootp;
|
||||||
#set clHW = concat (
|
|
||||||
# suffix (concat ("0", binary-to-ascii (16, 8, "", substring(hardware, 1, 1))),2), ":",
|
if substring (option vendor-class-identifier, 15, 5) = "00000" {
|
||||||
# suffix (concat ("0", binary-to-ascii (16, 8, "", substring(hardware, 2, 1))),2), ":",
|
filename "netboot.xyz.kpxe";
|
||||||
# suffix (concat ("0", binary-to-ascii (16, 8, "", substring(hardware, 3, 1))),2), ":",
|
} else {
|
||||||
# suffix (concat ("0", binary-to-ascii (16, 8, "", substring(hardware, 4, 1))),2), ":",
|
filename "netboot.xyz.efi";
|
||||||
# suffix (concat ("0", binary-to-ascii (16, 8, "", substring(hardware, 5, 1))),2), ":",
|
}
|
||||||
# suffix (concat ("0", binary-to-ascii (16, 8, "", substring(hardware, 6, 1))),2));
|
|
||||||
#if exists user-class and option user-class = "iPXE" {
|
|
||||||
# # set uri = concat("http://10.8.0.151:5000/gpxe/start/", clHW);
|
|
||||||
# # filename = uri;
|
|
||||||
# filename "boot.ipxe";
|
|
||||||
#} elsif substring (option vendor-class-identifier, 15, 5) = "00000" {
|
|
||||||
# filename "netboot.xyz.kpxe";
|
|
||||||
# #filename "ipxe.bin";
|
|
||||||
#} else {
|
|
||||||
# filename "netboot.xyz.efi";
|
|
||||||
#}
|
|
||||||
|
|
||||||
next-server 10.8.1.2;
|
next-server 10.8.1.2;
|
||||||
|
|
||||||
host dht21 {
|
host dht21 {
|
||||||
hardware ethernet 5c:cf:7f:06:9a:3e;
|
hardware ethernet 5c:cf:7f:06:9a:3e;
|
||||||
fixed-address 10.8.1.25;
|
fixed-address 10.8.1.25;
|
||||||
|
|
|
@ -0,0 +1,22 @@
|
||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
services.tftpd.enable = true;
|
||||||
|
services.tftpd.path = pkgs.linkFarm "netboot" [
|
||||||
|
{
|
||||||
|
name = "netboot.xyz.efi";
|
||||||
|
path = pkgs.fetchurl {
|
||||||
|
url = "https://github.com/netbootxyz/netboot.xyz/releases/download/2.0.48/netboot.xyz.efi";
|
||||||
|
sha256 = "1ch8ngryyr2abbrzpf0xb888a5d3rmnvfj8v0frfykhgs607666f";
|
||||||
|
#3b2de54224963ee17857a9737b65d49edc423e06ad7e9c9b85d9f69ca923676a";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
{
|
||||||
|
name = "netboot.xyz.kpxe";
|
||||||
|
path = pkgs.fetchurl {
|
||||||
|
url = "https://github.com/netbootxyz/netboot.xyz/releases/download/2.0.48/netboot.xyz.kpxe";
|
||||||
|
sha256 = "0p3qcdiialzbqjmiss6qay7qdz6b8mdsx5lk4hf75rlkwjh3yhax";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
Loading…
Reference in New Issue