Forráskód Böngészése

adding mirror varible to defaults and setting it so the user does not need to know one on boot

thelamer 5 éve
szülő
commit
5b32ebbb49

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

@@ -298,8 +298,12 @@ releases:
         code_name: "tumbleweed"
         code_name: "tumbleweed"
   oracle:
   oracle:
     name: "Oracle Linux"
     name: "Oracle Linux"
+    mirror: "https://yum.oracle.com"
     enabled: true
     enabled: true
     menu: "linux"
     menu: "linux"
+    paths:
+      7: "/repo/OracleLinux/OL7/latest/x86_64"
+      8: "/repo/OracleLinux/OL8/baseos/latest/x86_64" 
   parrotsec:
   parrotsec:
     name: "Parrot Security"
     name: "Parrot Security"
     mirror: "https://mirrordirector.archive.parrotsec.org"
     mirror: "https://mirrordirector.archive.parrotsec.org"

+ 2 - 1
roles/netbootxyz/templates/menu/oracle.ipxe.j2

@@ -23,6 +23,7 @@ goto ${version}
 {% if value.os == "oracle" %}
 {% if value.os == "oracle" %}
 :{{ value.version }}
 :{{ value.version }}
 set url ${live_endpoint}{{ value.path }}
 set url ${live_endpoint}{{ value.path }}
+set repo {{ releases.oracle.mirror }}{{ releases.oracle.paths[value.version|int] }}
 goto boot
 goto boot
 
 
 {% endif %}
 {% endif %}
@@ -30,7 +31,7 @@ goto boot
 
 
 :boot
 :boot
 imgfree
 imgfree
-kernel ${url}vmlinuz ${ipparam} root=live:${url}squashfs.img ro rd.live.image rd.lvm=0 rd.luks=0 rd.md=0 rd.dm=0 initrd=initrd
+kernel ${url}vmlinuz ${ipparam} repo=${repo} root=live:${url}squashfs.img ro rd.live.image rd.lvm=0 rd.luks=0 rd.md=0 rd.dm=0 initrd=initrd
 initrd ${url}initrd
 initrd ${url}initrd
 boot
 boot