per-tag configuration of mocks' --new-chroot

This commit is contained in:
Tomas Kopecek 2017-05-19 13:03:47 +02:00 committed by Mike McLean
parent 79560b1647
commit ffb88b93ca
2 changed files with 24 additions and 0 deletions

View file

@ -364,6 +364,11 @@ class BuildRoot(object):
#if self.options.debug_mock:
# cmd.append('--debug')
# TODO: should we pass something like --verbose --trace instead?
if 'mock.new_chroot' in self.config['extra']:
if self.config['extra']['mock.new_chroot']:
cmd.append('--new-chroot')
else:
cmd.append('--old-chroot')
cmd.extend(args)
self.logger.info(' '.join(cmd))
workdir = getattr(self, 'workdir', None)