Removed static port delcaration in the dhcpd templates
This commit is contained in:
@@ -16,7 +16,7 @@ option ipxe.no-pxedhcp 1;
|
||||
option architecture-type code 93 = unsigned integer 16;
|
||||
|
||||
if exists user-class and option user-class = "iPXE" {
|
||||
filename "http://{{$.Ipaddr}}:9873/ipxe/${mac:hexhyp}";
|
||||
filename "http://{{$.Ipaddr}}:{{.Port}}/ipxe/${mac:hexhyp}";
|
||||
} else {
|
||||
if option architecture-type = 00:0B {
|
||||
filename "/warewulf/arm64.efi";
|
||||
|
||||
@@ -16,7 +16,7 @@ option ipxe.no-pxedhcp 1;
|
||||
option architecture-type code 93 = unsigned integer 16;
|
||||
|
||||
if exists user-class and option user-class = "iPXE" {
|
||||
filename "http://{{$.Ipaddr}}:9873/ipxe/${mac:hexhyp}";
|
||||
filename "http://{{$.Ipaddr}}:{{.Port}}/ipxe/${mac:hexhyp}";
|
||||
} else {
|
||||
if option architecture-type = 00:0B {
|
||||
filename "/warewulf/arm64.efi";
|
||||
|
||||
@@ -4,6 +4,7 @@ import (
|
||||
"fmt"
|
||||
"os"
|
||||
"path"
|
||||
"strconv"
|
||||
"strings"
|
||||
"text/template"
|
||||
|
||||
@@ -17,6 +18,7 @@ import (
|
||||
|
||||
type dhcpTemplate struct {
|
||||
Ipaddr string
|
||||
Port string
|
||||
RangeStart string
|
||||
RangeEnd string
|
||||
Network string
|
||||
@@ -98,6 +100,7 @@ func Configure(show bool) error {
|
||||
}
|
||||
|
||||
d.Ipaddr = controller.Ipaddr
|
||||
d.Port = strconv.Itoa(controller.Warewulf.Port)
|
||||
d.Network = controller.Network
|
||||
d.Netmask = controller.Netmask
|
||||
d.RangeStart = controller.Dhcp.RangeStart
|
||||
|
||||
Reference in New Issue
Block a user