From: Eberhard Moenkeberg (emoenke_at_gwdg.de)
Date: Thu Aug 24 2006 - 03:43:30 CEST
Date: Thu, 24 Aug 2006 03:43:30 +0200 (CEST) From: Eberhard Moenkeberg <emoenke@gwdg.de> Message-ID: <Pine.LNX.4.61.0608240339150.27495@gwdu05.gwdg.de> Subject: Re: [suse-sles-e] Re: SLES10 YOU server
Hi,
On Wed, 16 Aug 2006, Marcus Meissner wrote:
>>> $ grep update.novell.com /var/lib/zypp/db/sources/* will result:
>>> <url>https://
>>>
>>> For using the URL remove the "?auth=digest" part.
>>>
>>> .../$RCE/SLED10-Updates/sles-10-i586/
>>> ^^ use arch of your system.
>>> ^^^ SLES10 for SLES
>>> ^ Real $ sign.
>>>
>>> id = content of /etc/zmd/deviceid
>>> pass = content of /etc/zmd/secret
>>>
>>> Unfortunately this does not work with wget, you need CURL or anything
>>> which is HTTP Digest Auth capable.
>>>
>>> I have attached a sample REPO-MD Mirror Script for your viewing pleasure.
>>> (It downloads, but I have not tested it as update source.)
>>
>> Wonderful. It does download. ;-))
>>
>> Can you please add the YOU path elements for SLE10-SDK too?
>
> Untested:
> ....$RCE/SLE10-SDK-Updates/$target
This is a summary about what I have found from Marcus' proposal:
#!/bin/bash
# trying to compensate the in SLE10 missing YOU-Server
# running only in a SLE10-System with matching license
# after a mail from Marcus Meissner <meissner@suse.de>
# in suse-sles-e@suse.com
# http://lists.suse.com/archive/suse-sles-e/2006-Jul/0113.html
# destination (creating subdirectories there):
DEST=/SA8/SLE10-YOU
# i586, ppc, s390x, ia64, or x86_64
#ARCH="x86_64"
ARCH="i586"
# SLES10 or SLED10 or SDK10
#SLE="SLES10"
SLE="SDK10"
# = = = = = nothing to configure below = = = = =
if [ -s /etc/zmd/deviceid ]; then
ID=`cat /etc/zmd/deviceid`
else
echo "file /etc/zmd/deviceid not OK."
exit 1
fi
if [ -s /etc/zmd/secret ]; then
PASS=`cat /etc/zmd/secret`
else
echo "file /etc/zmd/secret not OK."
exit 1
fi
if [ "$SLE." = "SLES10." ]; then
UPD="SLES10-Updates/sles-10"
elif [ "$SLE." = "SLED10." ]; then
UPD="SLED10-Updates/sled-10"
elif [ "$SLE." = "SDK10." ]; then
UPD="SLE10-SDK-Updates/sles-10"
else
echo "SLE wrong."
exit 1
fi
bn="https://${ID}:${PASS}@update.novell.com/repo/\$RCE/${UPD}-${ARCH}/"
echo $bn
mkdir -p ${DEST}/${SLE}/${ARCH}
cd ${DEST}/${SLE}/${ARCH}
mkdir repodata 2>/dev/null
curl -s --digest $bn/repodata/repomd.xml.asc -o repodata/repomd.xml.asc
curl -s --digest $bn/repodata/repomd.xml.key -o repodata/repomd.xml.key
curl -s --digest $bn/repodata/repomd.xml -o repodata/repomd.xml
curl -s --digest $bn/repodata/filelists.xml.gz -o
repodata/filelists.xml.gz
curl -s --digest $bn/repodata/primary.xml.gz -o repodata/primary.xml.gz
curl -s --digest $bn/repodata/patches.xml -o repodata/patches.xml
zcat repodata/primary.xml.gz|grep location.href| while read line ; do
uri=`echo "$line"|sed -e 's/^[^"]*"//;s/".*$//;'`
dn=`dirname $uri`
test -d $dn || mkdir -p $dn
test -f "$uri" || curl -s --digest "$bn/$uri" -o "$uri"
echo $uri
done
grep location.href repodata/patches.xml| while read line ; do
uri=`echo "$line"|sed -e 's/^[^"]*"//;s/".*$//;'`
dn=`dirname $uri`
test -d $dn || mkdir -p $dn
test -f "$uri" || curl -s --digest "$bn/$uri" -o "$uri"
echo $uri
done
Cheers -e
-- Eberhard Moenkeberg (emoenke@gwdg.de, em@kki.org) --------------------------------------------------------------------- To unsubscribe, e-mail: suse-sles-e-unsubscribe@suse.com For additional commands, e-mail: suse-sles-e-help@suse.com
This archive was generated by hypermail 2.1.7 : Thu Aug 24 2006 - 03:43:37 CEST