Antony Messerli 4 роки тому
батько
коміт
abc3a4f7e5

+ 2 - 1
CHANGELOG.md

@@ -7,8 +7,9 @@ All notable changes to this project will be documented in this file.
 ## [2.0.38]
 ### Added
 - Fedora 34 and Live Versions
-- Rescuezilla
 - Redo Rescue
+- Rescuezilla
+- Rocky Linux
 
 ### Changed
 - Switched to using upstream genfsimg for building hybrid images

+ 1 - 0
README.md

@@ -144,6 +144,7 @@ In addition to being able to host netboot.xyz locally, you can also create your
 | RancherOS | https://rancher.com/rancher-os | Yes | No |
 | Red Hat Enterprise Linux | https://www.redhat.com | User supplied media | No |
 | Regolith | https://regolith-linux.org | No | Yes |
+| Rocky Linux | https://rockylinux.org/ | Yes | No |
 | Scientific Linux | https://scientificlinux.org | Yes | No |
 | Septor | https://septor.sourceforge.io | No | Yes |
 | Slackware | https://www.slackware.com | Yes | No |

+ 9 - 0
roles/netbootxyz/defaults/main.yml

@@ -339,6 +339,15 @@ releases:
     enabled: true
     menu: linux
     name: Red Hat Enterprise Linux
+  rockylinux:
+    base_dir: pub/rocky
+    enabled: true
+    menu: linux
+    mirror: https://download.rockylinux.org
+    name: Rocky Linux
+    versions:
+    - code_name: 8.3
+      name: 8.3
   scientific:
     base_dir: linux/scientific
     enabled: true

+ 72 - 0
roles/netbootxyz/templates/menu/rockylinux.ipxe.j2

@@ -0,0 +1,72 @@
+#!ipxe
+
+# Rocky Linux
+# https://rockylinux.org/
+
+isset ${dhcp-server} && set ipparam ip=dhcp || set ipparam ip=${ip}::${gateway}:${netmask}:::none nameserver=${dns}
+set ipparam BOOTIF=${netX/mac} ${ipparam}
+
+goto ${menu} ||
+
+:rockylinux
+clear osversion
+set os {{ releases.rockylinux.name }}
+menu ${os} - ${arch}
+{% for item in releases.rockylinux.versions %}
+item {{ item.code_name }} ${space} ${os} {{ item.name }}
+{% endfor %}
+isset ${osversion} || choose osversion || goto linux_menu
+echo ${cls}
+set dir ${rockylinux_base_dir}/${osversion}/BaseOS/${arch}/os
+set repo ${rockylinux_mirror}/${dir}
+goto boottype
+
+:boottype
+set ova ${os} ${osversion}
+menu ${os} ${arch} boot type
+item graphical ${ova} graphical installer
+item text ${ova} text based installer
+item rescue ${ova} rescue
+item kickstart ${ova} set kickstart url [ ${ksurl} ]
+item kickstart_device ${ova} set ksdevice [ ${ksdevice} ]
+isset ${bt} || choose bt || goto rockylinux
+echo ${cls}
+iseq ${bt} text && goto text ||
+iseq ${bt} rescue && goto rescue ||
+iseq ${bt} kickstart && goto kickstart ||
+iseq ${bt} kickstart_device && goto kickstart_device ||
+goto bootos_images
+
+:text
+set params text ||
+goto bootos_images
+
+:rescue
+set params rescue ||
+goto bootos_images
+
+:kickstart
+echo -n Specify kickstart URL for ${os} ${osversion}: && read ksurl
+set params inst.ks=${ksurl} ||
+clear bt
+goto boottype
+
+:kickstart_device
+echo -n Specify ksdevice param for ${os} ${osversion}: && read ksdevice
+set ksdevice ${ksdevice} ||
+clear bt
+goto boottype
+
+:bootos_images
+imgfree
+kernel ${rockylinux_mirror}/${dir}/images/pxeboot/vmlinuz inst.repo=${repo} ${params} ${ipparam} initrd=initrd.img ${cmdline}
+initrd ${rockylinux_mirror}/${dir}/images/pxeboot/initrd.img
+echo
+echo MD5sums:
+md5sum vmlinuz initrd.img
+boot
+goto linux_menu
+
+:linux_menu
+clear menu
+exit 0