Split overlays into discrete functionality and test
- Closes #987 To make the overlays testable in isolation, and after discussion with the TSC, removed host/time/source from overlay files. Signed-off-by: Jonathon Anderson <janderson@ciq.com>
This commit is contained in:
40
overlays/ifcfg/rootfs/etc/sysconfig/network-scripts/ifcfg.ww
Normal file
40
overlays/ifcfg/rootfs/etc/sysconfig/network-scripts/ifcfg.ww
Normal file
@@ -0,0 +1,40 @@
|
||||
{{range $devname, $netdev := .NetDevs -}}
|
||||
{{- $filename := print "ifcfg-" $devname ".conf" }}
|
||||
{{- file $filename }}
|
||||
# This file is autogenerated by warewulf
|
||||
TYPE={{ $netdev.Type }}
|
||||
DEVICE={{ $netdev.Device }}
|
||||
NAME={{ $devname }}
|
||||
{{ if $netdev.MTU -}}
|
||||
MTU={{ $netdev.MTU }}
|
||||
{{ end -}}
|
||||
BOOTPROTO=static
|
||||
DEVTIMEOUT=10
|
||||
IPADDR={{ $netdev.Ipaddr }}
|
||||
NETMASK={{ $netdev.Netmask }}
|
||||
{{ if $netdev.Gateway -}}
|
||||
GATEWAY={{ $netdev.Gateway }}
|
||||
{{ end -}}
|
||||
{{ if $netdev.Hwaddr -}}
|
||||
HWADDR={{ $netdev.Hwaddr }}
|
||||
{{ end -}}
|
||||
{{ if $netdev.Type -}}
|
||||
TYPE={{ $netdev.Type }}
|
||||
{{ end -}}
|
||||
{{ if $netdev.OnBoot -}}
|
||||
ONBOOT={{ $netdev.OnBoot }}
|
||||
{{ end -}}
|
||||
IPV6INIT=yes
|
||||
IPV6_AUTOCONF=yes
|
||||
IPV6_DEFROUTE=yes
|
||||
IPV6_FAILURE_FATAL=no
|
||||
{{ if $netdev.Ipaddr6 -}}
|
||||
IPV6ADDR="{{ $netdev.Ipaddr6 }}"
|
||||
{{ end -}}
|
||||
{{range $tk, $tv := $netdev.Tags -}}
|
||||
{{ $prefix := substr 0 3 $tk -}}
|
||||
{{ if eq $prefix "DNS" -}}
|
||||
{{ $tk }}={{ $tv }}
|
||||
{{ end -}}
|
||||
{{ end -}}
|
||||
{{ end -}}
|
||||
Reference in New Issue
Block a user