From d4df0f78dbef7d35c2636fb00950cbe3fa988f53 Mon Sep 17 00:00:00 2001 From: Devon Bautista Date: Mon, 25 Nov 2024 16:11:57 -0700 Subject: [PATCH] fix(bootloop): add DHCP option 17 setting --- bootloop/main.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bootloop/main.go b/bootloop/main.go index fb786f1..3a6259e 100644 --- a/bootloop/main.go +++ b/bootloop/main.go @@ -137,6 +137,9 @@ func (p *PluginState) Handler4(req, resp *dhcpv4.DHCPv4) (*dhcpv4.DHCPv4, bool) debug.DebugRequest(log, req) + // Set root path to this server's IP + resp.Options.Update(dhcpv4.OptRootPath(resp.ServerIPAddr.String())) + record, ok := p.Recordsv4[req.ClientHWAddr.String()] hostname := req.HostName() cinfo := req.Options.Get(dhcpv4.OptionUserClassInformation)