Fix handling of CIDR values in warewulf.conf
- Fixes: #1541 - Fixes: #1594 Signed-off-by: Jonathon Anderson <janderson@ciq.com>
This commit is contained in:
@@ -152,7 +152,6 @@ option architecture-type code 93 = unsigned integer 16;
|
||||
if exists user-class and option user-class = "iPXE" {
|
||||
filename "http://192.168.0.1:9873/ipxe/${mac:hexhyp}?assetkey=${asset}&uuid=${uuid}";
|
||||
} else {
|
||||
|
||||
if option architecture-type = 00:00 {
|
||||
filename "/warewulf/undionly.kpxe";
|
||||
}
|
||||
@@ -166,7 +165,6 @@ if exists user-class and option user-class = "iPXE" {
|
||||
filename "/warewulf/snponly.efi";
|
||||
}
|
||||
}
|
||||
|
||||
subnet 192.168.0.0 netmask 255.255.255.0 {
|
||||
max-lease-time 120;
|
||||
range 192.168.0.100 192.168.0.199;
|
||||
@@ -201,7 +199,6 @@ option architecture-type code 93 = unsigned integer 16;
|
||||
if exists user-class and option user-class = "iPXE" {
|
||||
filename "http://192.168.0.1:9873/ipxe/${mac:hexhyp}?assetkey=${asset}&uuid=${uuid}";
|
||||
} else {
|
||||
|
||||
if option architecture-type = 00:00 {
|
||||
filename "/warewulf/undionly.kpxe";
|
||||
}
|
||||
@@ -215,7 +212,6 @@ if exists user-class and option user-class = "iPXE" {
|
||||
filename "/warewulf/snponly.efi";
|
||||
}
|
||||
}
|
||||
|
||||
subnet 192.168.0.0 netmask 255.255.255.0 {
|
||||
max-lease-time 120;
|
||||
range 192.168.0.100 192.168.0.199;
|
||||
@@ -278,7 +274,6 @@ dhcp-host=e6:92:39:49:7b:04,set:warewulf,node2,192.168.3.23,infinite
|
||||
const host_exports string = `backupFile: true
|
||||
writeFile: true
|
||||
Filename: etc/exports
|
||||
|
||||
# This file is autogenerated by warewulf
|
||||
/home 192.168.0.0/255.255.255.0(rw,sync)
|
||||
/opt 192.168.0.0/255.255.255.0(ro,sync,no_root_squash)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{{if $.Dhcp.Enabled -}}
|
||||
{{ if $.Dhcp.Enabled -}}
|
||||
# This file is autogenerated by warewulf
|
||||
|
||||
allow booting;
|
||||
@@ -38,19 +38,21 @@ if substring (option vendor-class-identifier, 0, 9) = "PXEClient" {
|
||||
if exists user-class and option user-class = "iPXE" {
|
||||
filename "http://{{$.Ipaddr}}:{{$.Warewulf.Port}}/ipxe/${mac:hexhyp}?assetkey=${asset}&uuid=${uuid}";
|
||||
} else {
|
||||
{{range $type,$name := $.Tftp.IpxeBinaries }}
|
||||
{{- range $type, $name := $.Tftp.IpxeBinaries }}
|
||||
if option architecture-type = {{ $type }} {
|
||||
filename "/warewulf/{{ basename $name }}";
|
||||
}
|
||||
{{- end }}{{/* range IpxeBinaries */}}
|
||||
{{- end }}
|
||||
}
|
||||
{{- end }}{{/* BootMethod */}}
|
||||
{{- end }}
|
||||
|
||||
subnet {{$.Network}} netmask {{$.Netmask}} {
|
||||
{{- if and .Network .Netmask .Dhcp.RangeStart .Dhcp.RangeEnd }}
|
||||
subnet {{.Network}} netmask {{.Netmask}} {
|
||||
max-lease-time 120;
|
||||
range {{$.Dhcp.RangeStart}} {{$.Dhcp.RangeEnd}};
|
||||
range {{.Dhcp.RangeStart}} {{.Dhcp.RangeEnd}};
|
||||
next-server {{.Ipaddr}};
|
||||
}
|
||||
{{- end }}
|
||||
|
||||
{{- if eq .Dhcp.Template "static" }}
|
||||
{{- range $nodes := $.AllNodes}}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{{- if .Nfs.Enabled }}
|
||||
{{ if .Nfs.Enabled -}}
|
||||
# This file is autogenerated by warewulf
|
||||
{{- $network := .Network }}
|
||||
{{- $netmask := .Netmask }}
|
||||
|
||||
Reference in New Issue
Block a user