Skip to content

Commit

Permalink
Fixes #37862 - Support EFI boot on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
sbernhard authored and evgeni committed Nov 21, 2024
1 parent d39c419 commit f295d1c
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,16 @@ ping --count 1 ${netX/dns} || echo Ping to DNS failed or ping command not availa
set boot-url tftp://<%= foreman_request_addr %>/
kernel ${boot-url}<%= @host.operatingsystem.bootfile(medium_provider,:kernel) %>

iseq ${platform} efi && goto win_efi || goto win_legacy

:win_efi
initrd -n peSetup.cmd <%= foreman_url('script') %> peSetup.cmd
goto boot

:win_legacy
initrd <%= foreman_url('script') %> peSetup.cmd

:boot
initrd ${boot-url}<%= @host.operatingsystem.bootfile(medium_provider,:bcd) %> BCD
initrd ${boot-url}<%= @host.operatingsystem.bootfile(medium_provider,:bootsdi) %> boot.sdi
initrd ${boot-url}<%= @host.operatingsystem.bootfile(medium_provider,:bootwim) %> boot.wim
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,16 @@ description: |
set boot-url http://<%= foreman_request_addr %>/httpboot/
kernel ${boot-url}<%= @host.operatingsystem.bootfile(medium_provider,:kernel) %>

iseq ${platform} efi && goto win_efi || goto win_legacy

:win_efi
initrd -n peSetup.cmd <%= foreman_url('script') %> peSetup.cmd
goto boot

:win_legacy
initrd <%= foreman_url('script') %> peSetup.cmd

:boot
initrd ${boot-url}<%= @host.operatingsystem.bootfile(medium_provider,:bcd) %> BCD
initrd ${boot-url}<%= @host.operatingsystem.bootfile(medium_provider,:bootsdi) %> boot.sdi
initrd ${boot-url}<%= @host.operatingsystem.bootfile(medium_provider,:bootwim) %> boot.wim
Expand Down

0 comments on commit f295d1c

Please sign in to comment.