From 6f87bab02a6f1fc2025a1ed077cae8656eae5767 Mon Sep 17 00:00:00 2001 From: Tahlia Richardson <3069029+tahliar@users.noreply.github.com> Date: Fri, 10 May 2024 10:49:11 +1000 Subject: [PATCH] SLL 7 script and requirements update (#21) * Reinstate script download step Updated script for EL7 is now available via RMT * Add yum-utils requirement for SLL7 jsc#DOCTEAM-1403 --- xml/register-with-rmt.xml | 63 +++++++-------------------------------- 1 file changed, 10 insertions(+), 53 deletions(-) diff --git a/xml/register-with-rmt.xml b/xml/register-with-rmt.xml index 7a61f74..2be5480 100644 --- a/xml/register-with-rmt.xml +++ b/xml/register-with-rmt.xml @@ -41,7 +41,7 @@ - The &rmt; server is running rmt-server version 2.10 or later. + The &rmt; server is running rmt-server version 2.15 or later. @@ -55,6 +55,13 @@ or CentOS Linux &productnumber;. + + + The package yum-utils is installed on the system you want to register. + This package is installed by default in most installations, but not in a + Minimal Install. + + You have a &productname; subscription activated in the &scc;. @@ -70,60 +77,10 @@ Registering &rhla; or CentOS Linux with &rmt; - - - - Save the following script as rmt-client-setup-res: - -#! /bin/sh - -SUSECONNECT=/usr/bin/SUSEConnect -RPM=/usr/bin/rpm -CURL=/usr/bin/curl -YUM=/usr/bin/yum -YUM_CONFIG_MGR=/usr/bin/yum-config-manager - -TEMPFILE="/etc/pki/ca-trust/source/anchors/rmt.crt" -UPDATE_CA_TRUST=/usr/bin/update-ca-trust -RPM_GPG_KEY_LOCATION="/etc/pki/rpm-gpg" - -PARAMS=$@ -REGURL="" -RMTNAME="" -REGURL=$1 - -CERTURL=`echo "$REGURL" | awk -F/ '{print "https://" $3 "/rmt.crt"}'` -$CURL --tlsv1.2 --silent --insecure --connect-timeout 10 --output $TEMPFILE $CERTURL -$UPDATE_CA_TRUST enable -$UPDATE_CA_TRUST extract - -SLL_version=7 -SLL_name="RES"; -SLL_release_package="sles_es-release-server" - -echo "Importing repomd.xml.key" -$CURL --silent --show-error --insecure ${REGURL}/repo/SUSE/Updates/${SLL_name}/${SLL_version}/x86_64/update/repodata/repomd.xml.key --output repomd.xml.key -$RPM --import repomd.xml.key - -echo "Disabling all repositories" -$YUM_CONFIG_MGR --disable \* > /dev/null - -if [ -f /usr/share/redhat-release ] | [ -h /usr/share/redhat-release ]; then - rm -f /usr/share/redhat-release; -fi - -$YUM_CONFIG_MGR --add-repo ${REGURL}/repo/SUSE/Updates/${SLL_name}/${SLL_version}/x86_64/update -$YUM_CONFIG_MGR --enable *suse.* > /dev/null - -$YUM install sles_es-release-server suseconnect-ng librepo -$YUM update yum - -$CURL --silent --show-error --insecure $REGURL/tools/rmt-client-setup --output rmt-client-setup -echo "Running rmt-client-setup $PARAMS" -sh rmt-client-setup $PARAMS +&prompt.root;curl http://RMT_SERVER/tools/rmt-client-setup-res --output rmt-client-setup-res