Signed-off-by: Daniel P. Berrange <berrange@xxxxxxxxxx> --- configure.ac | 1 + data/install-scripts/Makefile.am | 5 +- data/install-scripts/debian.org/Makefile.am | 1 + .../debian-preseed-desktop.xml.in} | 128 --------------------- .../debian.org/debian-preseed-jeos.xml.in | 127 ++++++++++++++++++++ 5 files changed, 133 insertions(+), 129 deletions(-) create mode 100644 data/install-scripts/debian.org/Makefile.am rename data/install-scripts/{debian.xml => debian.org/debian-preseed-desktop.xml.in} (59%) create mode 100644 data/install-scripts/debian.org/debian-preseed-jeos.xml.in diff --git a/configure.ac b/configure.ac index d2c8c17..72eff54 100644 --- a/configure.ac +++ b/configure.ac @@ -177,6 +177,7 @@ AC_CONFIG_FILES([ data/platforms/redhat.com/Makefile data/platforms/xen.org/Makefile data/install-scripts/Makefile + data/install-scripts/debian.org/Makefile data/oses/Makefile data/oses/altlinux.org/Makefile data/oses/apple.com/Makefile diff --git a/data/install-scripts/Makefile.am b/data/install-scripts/Makefile.am index 78decc2..875cf77 100644 --- a/data/install-scripts/Makefile.am +++ b/data/install-scripts/Makefile.am @@ -1,7 +1,10 @@ +SUBDIRS = \ + debian.org \ + $(NULL) + databasedir = $(pkgdatadir)/db/install-scripts/ database_DATA = \ - debian.xml \ fedora.xml \ rhel.xml \ ubuntu.xml \ diff --git a/data/install-scripts/debian.org/Makefile.am b/data/install-scripts/debian.org/Makefile.am new file mode 100644 index 0000000..ee4552b --- /dev/null +++ b/data/install-scripts/debian.org/Makefile.am @@ -0,0 +1 @@ +include ../../Makefile.inc diff --git a/data/install-scripts/debian.xml b/data/install-scripts/debian.org/debian-preseed-desktop.xml.in similarity index 59% rename from data/install-scripts/debian.xml rename to data/install-scripts/debian.org/debian-preseed-desktop.xml.in index 770820f..d9ac99d 100644 --- a/data/install-scripts/debian.xml +++ b/data/install-scripts/debian.org/debian-preseed-desktop.xml.in @@ -1,132 +1,4 @@ <libosinfo version="0.0.1"> - <!-- JEOS PROFILE --> - <install-script id='http://debian.org/debian/preseed/jeos'> - <profile>jeos</profile> - <expected-filename>preseed.cfg</expected-filename> - <can-pre-install-drivers>true</can-pre-install-drivers> - <config> - <param name="admin-password" policy="optional"/> - <param name="l10n-keyboard" policy="optional" value-map="http://x.org/x11-keyboard"/> - <param name="l10n-timezone" policy="optional"/> - <param name="l10n-language" policy="optional"/> - <param name="target-disk" policy="optional"/> - </config> - <injection-method>initrd</injection-method> - <!-- FIXME: The need of an internet connection may be avoidable. It is - necessary for now since in this version the debian installer will - error out with a "bad archive mirror" message and refuse to continue - without user input. --> - <needs-internet>true</needs-internet> - <template> - <xsl:stylesheet - xmlns:xsl="http://www.w3.org/1999/XSL/Transform" - version="1.0"> - - <xsl:output method="text"/> - - <xsl:template name="target-disk"> - <xsl:choose> - <xsl:when test="config/target-disk != ''"> - <xsl:value-of select="config/target-disk"/> - </xsl:when> - <xsl:otherwise> - <xsl:text>/dev/vda</xsl:text> - </xsl:otherwise> - </xsl:choose> - </xsl:template> - - <xsl:template name="l10n-language"> - <xsl:choose> - <xsl:when test="config/l10n-language != '' and config/l10n-language != 'C'"> - <xsl:value-of select="config/l10n-language"/> - </xsl:when> - <xsl:otherwise> - <xsl:text>en_US</xsl:text> - </xsl:otherwise> - </xsl:choose> - </xsl:template> - - <xsl:template name="l10n-keyboard"> - <xsl:choose> - <xsl:when test="config/l10n-keyboard != '' and config/l10n-keyboard != 'C'"> - <xsl:value-of select="config/l10n-keyboard"/> - </xsl:when> - <xsl:otherwise> - <xsl:text>us</xsl:text> - </xsl:otherwise> - </xsl:choose> - </xsl:template> - - <xsl:template match="/command-line"> - <xsl:text> keyboard-configuration/xkb-keymap=</xsl:text> - <xsl:call-template name="l10n-keyboard"/> - <xsl:text> debconf/priority=critical</xsl:text> - </xsl:template> - -<xsl:template match="/install-script-config"> -d-i debian-installer/locale select <xsl:call-template name="l10n-language"/> -d-i console-setup/ask_detect boolean false -d-i console-setup/layoutcode string <xsl:call-template name="l10n-keyboard"/> - -d-i netcfg/choose_interface select auto -d-i netcfg/get_hostname string localhost -d-i netcfg/get_domain string localdomain -d-i netcfg/disable_dhcp boolean false -d-i mirror/http/proxy string -d-i netcfg/wireless_wep string - -d-i clock-setup/utc boolean true -d-i time/zone select <xsl:value-of select="config/l10n-timezone"/> - -d-i partman-auto/disk string <xsl:call-template name="target-disk"/> -d-i partman-auto/method string regular -d-i partman-auto/choose_recipe select home - -d-i partman/confirm_write_new_label boolean true -d-i partman/choose_partition select finish -d-i partman/confirm boolean true -d-i partman/confirm_nooverwrite boolean true - -d-i passwd/root-login boolean true -d-i passwd/make-user boolean false -<xsl:choose> - <xsl:when test="config/admin-password = ''"> -# Real password will be set later -d-i passwd/root-password password dummyPa55w0rd -d-i passwd/root-password-again password dummyPa55w0rd - </xsl:when> - <xsl:otherwise> -d-i passwd/root-password password <xsl:value-of select="config/admin-password"/> -d-i passwd/root-password-again password <xsl:value-of select="config/admin-password"/> - </xsl:otherwise> -</xsl:choose> - -tasksel tasksel/first multiselect standard - -# Workaround for https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=666974 -d-i grub-installer/only_debian boolean false -d-i grub-installer/bootdev string <xsl:call-template name="target-disk"/> - -d-i apt-setup/security_host string -d-i apt-setup/services-select multiselect -d-i apt-setup/volatile_host string -d-i apt-setup/security_host string - -d-i finish-install/reboot_in_progress note - -<xsl:choose> - <xsl:when test="config/admin-password = ''"> -# Delete password -d-i preseed/late_command string in-target passwd -d root - </xsl:when> -</xsl:choose> - -</xsl:template> - </xsl:stylesheet> - </template> - </install-script> - - <!-- DESKTOP PROFILE --> <install-script id='http://debian.org/debian/preseed/desktop'> <profile>desktop</profile> <expected-filename>preseed.cfg</expected-filename> diff --git a/data/install-scripts/debian.org/debian-preseed-jeos.xml.in b/data/install-scripts/debian.org/debian-preseed-jeos.xml.in new file mode 100644 index 0000000..13af8c1 --- /dev/null +++ b/data/install-scripts/debian.org/debian-preseed-jeos.xml.in @@ -0,0 +1,127 @@ +<libosinfo version="0.0.1"> + <install-script id='http://debian.org/debian/preseed/jeos'> + <profile>jeos</profile> + <expected-filename>preseed.cfg</expected-filename> + <can-pre-install-drivers>true</can-pre-install-drivers> + <config> + <param name="admin-password" policy="optional"/> + <param name="l10n-keyboard" policy="optional" value-map="http://x.org/x11-keyboard"/> + <param name="l10n-timezone" policy="optional"/> + <param name="l10n-language" policy="optional"/> + <param name="target-disk" policy="optional"/> + </config> + <injection-method>initrd</injection-method> + <!-- FIXME: The need of an internet connection may be avoidable. It is + necessary for now since in this version the debian installer will + error out with a "bad archive mirror" message and refuse to continue + without user input. --> + <needs-internet>true</needs-internet> + <template> + <xsl:stylesheet + xmlns:xsl="http://www.w3.org/1999/XSL/Transform" + version="1.0"> + + <xsl:output method="text"/> + + <xsl:template name="target-disk"> + <xsl:choose> + <xsl:when test="config/target-disk != ''"> + <xsl:value-of select="config/target-disk"/> + </xsl:when> + <xsl:otherwise> + <xsl:text>/dev/vda</xsl:text> + </xsl:otherwise> + </xsl:choose> + </xsl:template> + + <xsl:template name="l10n-language"> + <xsl:choose> + <xsl:when test="config/l10n-language != '' and config/l10n-language != 'C'"> + <xsl:value-of select="config/l10n-language"/> + </xsl:when> + <xsl:otherwise> + <xsl:text>en_US</xsl:text> + </xsl:otherwise> + </xsl:choose> + </xsl:template> + + <xsl:template name="l10n-keyboard"> + <xsl:choose> + <xsl:when test="config/l10n-keyboard != '' and config/l10n-keyboard != 'C'"> + <xsl:value-of select="config/l10n-keyboard"/> + </xsl:when> + <xsl:otherwise> + <xsl:text>us</xsl:text> + </xsl:otherwise> + </xsl:choose> + </xsl:template> + + <xsl:template match="/command-line"> + <xsl:text> keyboard-configuration/xkb-keymap=</xsl:text> + <xsl:call-template name="l10n-keyboard"/> + <xsl:text> debconf/priority=critical</xsl:text> + </xsl:template> + +<xsl:template match="/install-script-config"> +d-i debian-installer/locale select <xsl:call-template name="l10n-language"/> +d-i console-setup/ask_detect boolean false +d-i console-setup/layoutcode string <xsl:call-template name="l10n-keyboard"/> + +d-i netcfg/choose_interface select auto +d-i netcfg/get_hostname string localhost +d-i netcfg/get_domain string localdomain +d-i netcfg/disable_dhcp boolean false +d-i mirror/http/proxy string +d-i netcfg/wireless_wep string + +d-i clock-setup/utc boolean true +d-i time/zone select <xsl:value-of select="config/l10n-timezone"/> + +d-i partman-auto/disk string <xsl:call-template name="target-disk"/> +d-i partman-auto/method string regular +d-i partman-auto/choose_recipe select home + +d-i partman/confirm_write_new_label boolean true +d-i partman/choose_partition select finish +d-i partman/confirm boolean true +d-i partman/confirm_nooverwrite boolean true + +d-i passwd/root-login boolean true +d-i passwd/make-user boolean false +<xsl:choose> + <xsl:when test="config/admin-password = ''"> +# Real password will be set later +d-i passwd/root-password password dummyPa55w0rd +d-i passwd/root-password-again password dummyPa55w0rd + </xsl:when> + <xsl:otherwise> +d-i passwd/root-password password <xsl:value-of select="config/admin-password"/> +d-i passwd/root-password-again password <xsl:value-of select="config/admin-password"/> + </xsl:otherwise> +</xsl:choose> + +tasksel tasksel/first multiselect standard + +# Workaround for https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=666974 +d-i grub-installer/only_debian boolean false +d-i grub-installer/bootdev string <xsl:call-template name="target-disk"/> + +d-i apt-setup/security_host string +d-i apt-setup/services-select multiselect +d-i apt-setup/volatile_host string +d-i apt-setup/security_host string + +d-i finish-install/reboot_in_progress note + +<xsl:choose> + <xsl:when test="config/admin-password = ''"> +# Delete password +d-i preseed/late_command string in-target passwd -d root + </xsl:when> +</xsl:choose> + +</xsl:template> + </xsl:stylesheet> + </template> + </install-script> +</libosinfo> -- 2.4.3 _______________________________________________ Libosinfo mailing list Libosinfo@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libosinfo