[Libosinfo] [osinfo-db 2/2] install-script, suse: Add install-scripts for SLES 11 SP4
Christophe Fergeau
cfergeau at redhat.com
Tue May 2 11:07:51 UTC 2017
On Sun, Apr 23, 2017 at 12:41:31AM +0200, Fabiano Fidêncio wrote:
> Some small changes have been done in the bootloader and in the patterns
> currently used for SLES 12+ in order to also support the "old" SLES 11
> SP4.
>
> Signed-off-by: Fabiano Fidêncio <fabiano at fidencio.org>
> ---
> .../suse.com/suse-autoyast-desktop.xml.in | 34 ++++++++++++++++++++--
> .../suse.com/suse-autoyast-jeos.xml.in | 9 +++++-
> data/os/suse.com/sles-11.4.xml.in | 9 ++++--
> 3 files changed, 47 insertions(+), 5 deletions(-)
>
> diff --git a/data/install-script/suse.com/suse-autoyast-desktop.xml.in b/data/install-script/suse.com/suse-autoyast-desktop.xml.in
> index acb38c1..381d621 100644
> --- a/data/install-script/suse.com/suse-autoyast-desktop.xml.in
> +++ b/data/install-script/suse.com/suse-autoyast-desktop.xml.in
> @@ -86,7 +86,14 @@
> <timeout config:type="integer">8</timeout>
> <vgamode/>
> </global>
> - <loader_type>grub2</loader_type>
> + <xsl:choose>
> + <xsl:when test="os/version < 12">
> + <loader_type>grub</loader_type>
> + </xsl:when>
> + <xsl:otherwise>
> + <loader_type>grub2</loader_type>
> + </xsl:otherwise>
> + </xsl:choose>
> </bootloader>
> <firewall>
> <enable_firewall config:type="boolean">false</enable_firewall>
> @@ -172,13 +179,20 @@ if test -z '<xsl:value-of select="config/user-password"/>'; then
> pam-config -a --unix-nullok
> pam-config -a --nullok
>
> -<xsl:if test="os/version = 12">
> +<xsl:if test="os/version < 12.1">
I'd squash this hunk in the first patch. Does this mean we are not
adding any users with older suse?
> useradd <xsl:value-of select="config/user-login"/> -m -G users
> passwd -d <xsl:value-of select="config/user-login"/>
> </xsl:if>
>
> #Enable passwordless login for users that are part of the nopasswdlogin group
> +<xsl:choose>
> + <xsl:when test="os/version < 12">
> +sed -i '2 i auth sufficient pam_succeed_if.so user ingroup nopasswdlogin' /etc/pam.d/gdm
> + </xsl:when>
> + <xsl:otherwise>
> sed -i '4 i auth sufficient pam_succeed_if.so user ingroup nopasswdlogin' /etc/pam.d/gdm-password
> + </xsl:otherwise>
> +</xsl:choose>
Maybe you could match on the first empty line, and insert this line
before it to avoid the special casing here? (I don't have a suse at hand
to check this file content, tryin to guess after looking at my fedora
install).
> fi
>
> if test -n '<xsl:value-of select="config/avatar-location"/>'; then
> @@ -213,6 +227,15 @@ fi
> <pattern>base</pattern>
> <pattern>gnome-basic</pattern>
> <pattern>printing</pattern>
Shouldn't these 2 lines be removed?
Christophe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libosinfo/attachments/20170502/7568664a/attachment.sig>
More information about the Libosinfo
mailing list