[Libosinfo] [osinfo-db PATCH 1/9] fedora, kickstart: Accept initrd as injection-method

Fabiano Fidêncio fidencio at redhat.com
Fri Dec 21 14:09:32 UTC 2018


Signed-off-by: Fabiano Fidêncio <fidencio at redhat.com>
---
 .../fedora-kickstart-desktop.xml.in               | 15 ++++++++++++---
 .../fedora-kickstart-jeos.xml.in                  | 15 ++++++++++++---
 2 files changed, 24 insertions(+), 6 deletions(-)

diff --git a/data/install-script/fedoraproject.org/fedora-kickstart-desktop.xml.in b/data/install-script/fedoraproject.org/fedora-kickstart-desktop.xml.in
index e8e1622..01b315c 100644
--- a/data/install-script/fedoraproject.org/fedora-kickstart-desktop.xml.in
+++ b/data/install-script/fedoraproject.org/fedora-kickstart-desktop.xml.in
@@ -20,6 +20,7 @@
     <injection-method>cdrom</injection-method>
     <injection-method>disk</injection-method>
     <injection-method>floppy</injection-method>
+    <injection-method>initrd</injection-method>
     <avatar-format>
       <mime-type>image/png</mime-type>
     </avatar-format>
@@ -95,9 +96,17 @@
 	</xsl:template>
 
         <xsl:template match="/command-line">
-            <xsl:text>ks=hd:</xsl:text>
-            <xsl:call-template name="script-disk"/>
-            <xsl:text>:/</xsl:text>
+            <xsl:text>ks=</xsl:text>
+            <xsl:choose>
+              <xsl:when test="script/preferred-injection-method = 'initrd'">
+                <xsl:text>file:/</xsl:text>
+              </xsl:when>
+              <xsl:otherwise>
+                <xsl:text>hd:</xsl:text>
+                <xsl:call-template name="script-disk"/>
+                <xsl:text>:/</xsl:text>
+              </xsl:otherwise>
+            </xsl:choose>
             <xsl:value-of select="script/expected-filename"/>
         </xsl:template>
 
diff --git a/data/install-script/fedoraproject.org/fedora-kickstart-jeos.xml.in b/data/install-script/fedoraproject.org/fedora-kickstart-jeos.xml.in
index c4bda77..21f8aa8 100644
--- a/data/install-script/fedoraproject.org/fedora-kickstart-jeos.xml.in
+++ b/data/install-script/fedoraproject.org/fedora-kickstart-jeos.xml.in
@@ -15,6 +15,7 @@
     <injection-method>cdrom</injection-method>
     <injection-method>disk</injection-method>
     <injection-method>floppy</injection-method>
+    <injection-method>initrd</injection-method>
     <template>
       <xsl:stylesheet
         xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
@@ -87,9 +88,17 @@
 	</xsl:template>
 
         <xsl:template match="/command-line">
-            <xsl:text>ks=hd:</xsl:text>
-            <xsl:call-template name="script-disk"/>
-            <xsl:text>:/</xsl:text>
+            <xsl:text>ks=</xsl:text>
+            <xsl:choose>
+              <xsl:when test="script/preferred-injection-method = 'initrd'">
+                <xsl:text>file:/</xsl:text>
+              </xsl:when>
+              <xsl:otherwise>
+                <xsl:text>hd:</xsl:text>
+                <xsl:call-template name="script-disk"/>
+                <xsl:text>:/</xsl:text>
+              </xsl:otherwise>
+            </xsl:choose>
             <xsl:value-of select="script/expected-filename"/>
         </xsl:template>
 
-- 
2.19.2




More information about the Libosinfo mailing list