Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Debian User (http://www.linux-archive.org/debian-user/)
-   -   Fix dumping of repositories into anaconda-ks.cfg (http://www.linux-archive.org/debian-user/433790-fix-dumping-repositories-into-anaconda-ks-cfg.html)

Radek Vykydal 09-30-2010 02:26 PM

Fix dumping of repositories into anaconda-ks.cfg
 
---
pyanaconda/__init__.py | 2 +-
pyanaconda/backend.py | 2 +-
pyanaconda/yuminstall.py | 20 ++++++++++----------
3 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/pyanaconda/__init__.py b/pyanaconda/__init__.py
index 9d94519..39fb53c 100644
--- a/pyanaconda/__init__.py
+++ b/pyanaconda/__init__.py
@@ -400,7 +400,7 @@ class Anaconda(object):
self.bootloader.writeKS(f)

if self.backend:
- self.backend.writeKS(f)
+ self.backend.writeKS(f, self.repos)
self.backend.writePackagesKS(f, self)

# Also write out any scripts from the input ksfile.
diff --git a/pyanaconda/backend.py b/pyanaconda/backend.py
index f7c9078..6166d2c 100644
--- a/pyanaconda/backend.py
+++ b/pyanaconda/backend.py
@@ -255,7 +255,7 @@ class AnacondaBackend:

# write out any other kickstart bits the backend requires - no warning
# here because this may not be needed
- def writeKS(self, f):
+ def writeKS(self, f, anaconda):
pass

def getRequiredMedia(self):
diff --git a/pyanaconda/yuminstall.py b/pyanaconda/yuminstall.py
index 551cf0d..47ba336 100644
--- a/pyanaconda/yuminstall.py
+++ b/pyanaconda/yuminstall.py
@@ -2041,22 +2041,22 @@ reposdir=/etc/anaconda.repos.d,/tmp/updates/anaconda.repos.d,/tmp/product/anacon

line = "repo --name="%s" " % (repo.name or repo.repoid)

- if repo.baseurl:
- line += " --baseurl=%s" % repo.anacondaBaseURLs[0]
+ if repo.mirrorlist:
+ line += " --mirrorlist=%s" % repo.url
else:
- line += " --mirrorlist=%s" % repo.mirrorlist
+ line += " --baseurl=%s" % repo.url

- if repo.proxy:
+ if repo.yumrepo.proxy:
line += " --proxy="%s"" % repo.proxy_dict['http']

- if repo.cost:
- line += " --cost=%s" % repo.cost
+ if repo.yumrepo.cost:
+ line += " --cost=%s" % repo.yumrepo.cost

- if repo.includepkgs:
- line += " --includepkgs="%s"" % ",".join(repo.includepkgs)
+ if repo.yumrepo.includepkgs:
+ line += " --includepkgs="%s"" % ",".join(repo.yumrepo.includepkgs)

- if repo.exclude:
- line += " --excludepkgs="%s"" % ",".join(repo.exclude)
+ if repo.yumrepo.exclude:
+ line += " --excludepkgs="%s"" % ",".join(repo.yumrepo.exclude)

line += "
"

--
1.7.2

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


All times are GMT. The time now is 06:34 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.