utils.ipxe 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. #!ipxe
  2. menu Utilities
  3. item --gap Utilities:
  4. item clonezilla ${space} Clonezilla
  5. item hdt ${space} Hardware Detection Tool
  6. item memtest ${space} MemTest86+
  7. item testpr ${space} Test netboot.xyz branch
  8. choose --default ${menu} menu || goto utils_exit
  9. echo ${cls}
  10. goto ${menu} ||
  11. chain ${menu}.ipxe || goto error
  12. goto linux_exit
  13. :hdt
  14. kernel ${memdisk} iso raw
  15. initrd http://www.hdt-project.org/raw-attachment/wiki/hdt-0.5.0/hdt-0.5.2.iso
  16. boot
  17. goto utils_exit
  18. :clonezilla
  19. set version 2.4.2-61
  20. iseq ${arch} x86_64 && set cz_arch amd64 || set cz_arch i686-pae
  21. set project clonezilla
  22. set iso ${project}_live_stable/${version}/${project}-live-${version}-${cz_arch}.iso
  23. set czurl http://sourceforge.net/projects/clonezilla/files/${iso}/download
  24. kernel ${memdisk} iso raw ${params}
  25. :retry
  26. iseq ${try} xxxxx && exit ||
  27. set try ${try}x
  28. initrd ${czurl} || goto retry
  29. boot || goto utils_exit
  30. :memtest
  31. chain utils/memtest.bin ${params} && goto main_menu ||
  32. echo MEMORY ERROR DETECTED! ${errno}
  33. echo Press any key to continue ...
  34. read a
  35. goto utils_exit
  36. :testpr
  37. echo This will chainload into a testing branch of netboot.xyz. You'll need to enter
  38. echo your Github User and the first part of the commit hash of the commit you want
  39. echo to test. This assumes you are testing from a netboot.xyz repo.
  40. echo
  41. echo -n Specify Github User Name: ${} && read github_user
  42. echo -n Specify shortened commit hash of netboot.xyz to be tested ( i.e. 30b7ca ): ${} && read github_hash
  43. echo
  44. echo Attempting to chainload:
  45. chain --autofree https://raw.githubusercontent.com/${github_user}/netboot.xyz/${github_hash}/src/menu.ipxe || goto error
  46. goto utils_exit
  47. :utils_exit
  48. clear menu
  49. chain menu.ipxe
  50. exit 0