remved hosts.tmpl as not needed any more

This commit is contained in:
Christian Goll
2022-02-17 10:59:12 +01:00
committed by jcsiadal
parent 9b7c0e9f05
commit f0075fb94c
2 changed files with 0 additions and 16 deletions

View File

@@ -148,7 +148,6 @@ files: all
install -d -m 0755 $(DESTDIR)$(FIREWALLDDIR)
install -d -m 0755 $(DESTDIR)$(SYSTEMDDIR)
test -f $(DESTDIR)$(SYSCONFDIR)/warewulf/warewulf.conf || install -m 644 etc/warewulf.conf $(DESTDIR)$(SYSCONFDIR)/warewulf/
test -f $(DESTDIR)$(SYSCONFDIR)/warewulf/hosts.tmpl || install -m 644 etc/hosts.tmpl $(DESTDIR)$(SYSCONFDIR)/warewulf/
test -f $(DESTDIR)$(SYSCONFDIR)/warewulf/nodes.conf || install -m 644 etc/nodes.conf $(DESTDIR)$(SYSCONFDIR)/warewulf/
cp -r etc/examples $(DESTDIR)$(SYSCONFDIR)/warewulf/
cp -r etc/ipxe $(DESTDIR)$(SYSCONFDIR)/warewulf/

View File

@@ -1,15 +0,0 @@
{{$.PrevHostFile}}# Do not edit after this line - these host entries are maintained by warewulf
{{range $node := $.AllNodes}} {{/* for each node */}}
# Entry for {{$node.Id.Get}}
{{- range $devname, $netdev := $node.NetDevs}} {{/* for each network device on the node */}}
{{- if $netdev.Ipaddr.Defined}} {{/* if we have an ip address on this network device */}}
{{- if $netdev.Default.GetB}} {{/* emit the node name as hostname if this is the default */}}
{{$netdev.Ipaddr.Get}} {{$node.Id.Get}} {{$node.Id.Get}}-{{$devname}} {{$node.Id.Get}}-{{$netdev.Device.Get}}
{{- else}}
{{$netdev.Ipaddr.Get}} {{$node.Id.Get}}-{{$devname}} {{$node.Id.Get}}-{{$netdev.Device.Get}}
{{- end}} {{/* end if default */}}
{{- end}} {{/* end if ip */}}
{{- end}} {{/* end for each network device */}}
{{end}} {{/* end for each node */}}