airshipctl/manifests/function/baremetal-operator/config-file/dualboot.ipxe
Nikolay Fedorov 68aa064e93 Add Bare Metal Operator Ironic config files
Relates-To: #105

Change-Id: I948b48c5c8bacf21dd220b9975124e0bccf1fa58
2020-03-20 10:55:56 +04:00

23 lines
738 B
Plaintext

#!ipxe
# NOTE(lucasagomes): Loop over all network devices and boot from
# the first one capable of booting. For more information see:
# https://bugs.launchpad.net/ironic/+bug/1504482
set netid:int32 -1
:loop
inc netid
isset ${net${netid}/mac} || chain pxelinux.cfg/${mac:hexhyp} || goto inspector
echo Attempting to boot from MAC ${net${netid}/mac:hexhyp}
chain pxelinux.cfg/${net${netid}/mac:hexhyp} || goto loop
# If no networks configured to boot then introspect first valid one
:inspector
chain inspector.ipxe || goto loop_done
:loop_done
echo PXE boot failed! No configuration found for any of the present NICs
echo and could not find inspector.ipxe to use as fallback.
echo Press any key to reboot...
prompt --timeout 180
reboot