diff --git a/playbooks/roles/ironic-install/files/boot.ipxe b/playbooks/roles/ironic-install/files/boot.ipxe index 25a0ea8dc..ce2e43054 100644 --- a/playbooks/roles/ironic-install/files/boot.ipxe +++ b/playbooks/roles/ironic-install/files/boot.ipxe @@ -1,7 +1,11 @@ #!ipxe +isset ${mac:hexhyp} && goto boot_system || +chain ipxe.pxe + # load the MAC-specific file or fail if it's not found -chain --autofree pxelinux.cfg/${mac:hexraw} || goto error_no_config +:boot_system +chain pxelinux.cfg/${mac:hexhyp} || goto error_no_config :error_no_config echo PXE boot failed. No configuration found for MAC ${mac} diff --git a/playbooks/roles/ironic-install/tasks/create_tftpboot.yml b/playbooks/roles/ironic-install/tasks/create_tftpboot.yml index f6da95a2e..2b63a654a 100644 --- a/playbooks/roles/ironic-install/tasks/create_tftpboot.yml +++ b/playbooks/roles/ironic-install/tasks/create_tftpboot.yml @@ -37,6 +37,11 @@ copy: src=xinetd.tftp dest=/etc/xinetd.d/tftp - name: "Copy iPXE image into place" copy: src={{ ipxe_dir }}/undionly.kpxe dest=/tftpboot/ +# NOTE(TheJulia): Copy full iPXE chain loader images in case they are required. +- name: "Copy full iPXE image into /httpboot" + copy: src={{ ipxe_dir }}/ipxe.pxe dest=/httpboot/ +- name: "Copy full iPXE image into /tftpboot" + copy: src={{ ipxe_dir }}/ipxe.pxe dest=/tftpboot/ # Similar logic to below can be utilized to retrieve files - name: "Determine if folder exists, else create and populate folder." stat: path=/tftpboot/master_images diff --git a/playbooks/roles/ironic-install/templates/dnsmasq.conf.j2 b/playbooks/roles/ironic-install/templates/dnsmasq.conf.j2 index 7de48e779..89794eb82 100644 --- a/playbooks/roles/ironic-install/templates/dnsmasq.conf.j2 +++ b/playbooks/roles/ironic-install/templates/dnsmasq.conf.j2 @@ -433,6 +433,9 @@ dhcp-range={{dhcp_pool_start}},{{dhcp_pool_end}},12h # Boot for Etherboot gPXE. The idea is to send two different # filenames, the first loads gPXE, and the second tells gPXE what to # load. The dhcp-match sets the gpxe tag for requests from gPXE. +dhcp-userclass=set:gpxe,"gPXE" +dhcp-boot=tag:gpxe,ipxe.pxe + dhcp-match=set:ipxe,175 # iPXE sends a 175 option. dhcp-boot=tag:!ipxe,undionly.kpxe {% if testing %}