gather: Display source repo of packages

When multiple repos are configured in pkgset_repos, the logs should
contain information on where exactly the package was pulled from. The
log file in question should be in
`logs/<arch>/pkgset_source.<arch>.log`.

Fixes: #545
Signed-off-by: Lubomír Sedlář <lsedlar@redhat.com>
This commit is contained in:
Lubomír Sedlář 2017-06-07 15:07:07 +02:00
parent c337018294
commit 4fb28979cf
1 changed files with 4 additions and 5 deletions

View File

@ -1211,11 +1211,10 @@ class Pungi(PungiBase):
"""Cycle through the list of package objects and """Cycle through the list of package objects and
download them from their respective repos.""" download them from their respective repos."""
downloads = [] for pkg in sorted(polist):
for pkg in polist: repo = self.ayum.repos.getRepo(pkg.repoid)
downloads.append('%s.%s' % (pkg.name, pkg.arch)) self.logger.info("Downloading %s.%s from %s",
downloads.sort() pkg.name, pkg.arch, repo.baseurl or repo.mirrorlist)
self.logger.info("Download list: %s" % downloads)
pkgdir = os.path.join(self.config.get('pungi', 'destdir'), pkgdir = os.path.join(self.config.get('pungi', 'destdir'),
self.config.get('pungi', 'version'), self.config.get('pungi', 'version'),