Skip to content

Instantly share code, notes, and snippets.

@lzap

lzap/dhcpd.conf

Last active Aug 11, 2020
Embed
What would you like to do?
UEFI HTTPBoot Foreman config for discovery
omapi-port 7911;
default-lease-time 43200;
max-lease-time 86400;
not authoritative;
ddns-update-style none;
option domain-name "nat.lan";
option domain-name-servers 192.168.199.15;
option ntp-servers none;
allow booting;
allow bootp;
option fqdn.no-client-update on;
option fqdn.rcode2 255;
option pxegrub code 150 = text;
set vendor-string = option vendor-class-identifier;
log-facility local7;
include "/etc/dhcp/dhcpd.hosts";
class "httpclients" {
match if substring(option vendor-class-identifier, 0, 10) = "HTTPClient";
option vendor-class-identifier "HTTPClient";
if option architecture = 00:0F {
filename "http://192.168.199.15:8000/EFI/grub2/shimia32.efi";
} else if option architecture = 00:10 {
filename "http://192.168.199.15:8000/EFI/grub2/shim.efi";
}
}
class "pxeclients" {
match if substring (option vendor-class-identifier, 0, 9) = "PXEClient";
next-server 192.168.199.15;
if exists user-class and option user-class = "iPXE" {
filename "http://192.168.199.15:8000/unattended/iPXE";
} else if option architecture = 00:06 {
filename "grub2/shimia32.efi";
} else if option architecture = 00:07 {
filename "grub2/shim.efi";
} else {
filename "pxelinux.0";
}
}
# subnet definitions
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment