Explorar o código

add bootstrapping by mac address or hostname to default file if booting from a TFTP server

thelamer %!s(int64=5) %!d(string=hai) anos
pai
achega
9d25a45ac6
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      roles/netbootxyz/templates/disks/netboot.xyz.j2

+ 2 - 0
roles/netbootxyz/templates/disks/netboot.xyz.j2

@@ -50,6 +50,8 @@ echo Attempting chainload of ${boot_domain}...
 goto menu || goto failsafe
 
 :tftpmenu
+isset ${hostname} && chain --autofree tftp://${next-server}/HOSTNAME-${hostname}.ipxe || echo Custom boot by Hostname not found trying MAC...
+chain --autofree tftp://${next-server}/MAC-${mac:hexraw}.ipxe || echo Custom boot by MAC not found booting default...
 chain --autofree tftp://${next-server}/menu.ipxe || echo ${TFTP_ERR} && goto menu
 
 :menu