Mailinglist Archive: zypp-devel (64 mails)

< Previous Next >
[zypp-devel] How to get "zypper" to work in an Autoyast post-install script?
  • From: "Wil Decius" <wilson.decius@xxxxxxxxx>
  • Date: Tue, 22 Jul 2008 09:40:13 -0700
  • Message-id: <769e0ec0807220940w2f949285t59528b26e20a5a0d@xxxxxxxxxxxxxx>
I execute a number of post-install scripts in an AutoYast setup.

No problems except for one ...

<listentry>
<filename>001_REPO_SETUP</filename>
<interpreter>shell</interpreter>
<source><![CDATA[#!/bin/tcsh
cd /etc/zypp
mv repos.d repos.d.D
mkdir -p repos.d.R
ln -sf repos.d.R repos.d

/usr/bin/zypper ar -t yast2
http://download.opensuse.org/distribution/11.0/repo/oss/ "OSS" >&
tmp.txt
]]></source>
</listentry>


After install & boot, I see

ls -ald /etc/zypp/repos.d*
lrwxrwxrwx 1 root root 15 2008-07-22 08:49 /etc/zypp/repos.d -> repos.d.R/
drwxr-xr-x 2 root root 4096 2008-07-22 08:46 /etc/zypp/repos.d.D/
drwxr-xr-x 2 root root 4096 2008-07-22 08:49 /etc/zypp/repos.d.R/

but,

ls -al /etc/zypp/repos.d/*


shows no repos created.

Checking in

cat tmp.txt
Specified local path does not exist or is not accessible.

@ shell the script works just fine, populating the "repos.d" dir with
the new "*.repo" definition file.

ls -al /etc/zypp/repos.d/
zypper ar -t yast2
http://download.opensuse.org/distribution/11.0/repo/oss/ "OSS"
Adding repository 'OSS' [done]
Repository 'OSS' successfully added
Enabled: Yes
Autorefresh: No
URI: http://download.opensuse.org/distribution/11.0/repo/oss/
ls -al /etc/zypp/repos.d/
-rw-r--r-- 1 root root 138 2008-07-22 09:30 OSS.repo

Why won't zypper used in the autoyast-script populate the dir?

Guess is that something's not ready/installed @ that point in install
... but what?

Wil
--
To unsubscribe, e-mail: zypp-devel+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-devel+help@xxxxxxxxxxxx

< Previous Next >
This Thread
Follow Ups