Use url line in kickstart files as a repo

This commit is contained in:
Jesse Keating 2007-09-12 16:42:06 -04:00 committed by Jesse Keating
parent 788105f59b
commit 4cb9239814
2 changed files with 8 additions and 0 deletions

View File

@ -3,6 +3,7 @@
- Consolidate the download code for easier maint. (Mark McLoughlin)
- Create a config class that can make using pungi modules easier. (Mark
McLoughlin)
- Use url line in kickstart files as a repo
* Tue Sep 11 2007 Jesse Keating <jkeating@redhat.com>
- Fix a bug with default dest dir (notting)

View File

@ -100,6 +100,13 @@ class Gather(pypungi.PungiBase):
arches.append('src') # throw source in there, filter it later
# deal with our repos
# Check to see if method was url, add that to the repo list.
if ksparser.handler.method.url:
reponame = "ks-method-url"
repourl = ksparser.handler.method.url
newrepo = ksparser.handler.RepoData(name=reponame, baseurl=repourl)
ksparser.handler.repo.add(newrepo)
for repo in ksparser.handler.repo.repoList:
self.logger.info('Adding repo %s' % repo.name)
thisrepo = yum.yumRepo.YumRepository(repo.name)