add "yum_proxy" option to builder
Previously if you wanted to use an HTTP proxy server with a builder, you had to either specify the proxy in the pkgurl, or use iptables to intercept HTTP and route it through a transparent proxy. There is a better way: yum has proxy support built in. When a URL is specified in the "proxy" option in yum.conf, yum will use this URL as a proxy server. Add a "yum_proxy" option in kojid.conf. Kojid will pass it back to mock during genMockConfig(). Mock will write it into yum.conf in the chroot.
This commit is contained in:
parent
2976de313f
commit
97bd601080
2 changed files with 8 additions and 2 deletions
|
|
@ -204,7 +204,7 @@ class BuildRoot(object):
|
|||
for k in ('repoid', 'tag_name'):
|
||||
if hasattr(self, k):
|
||||
opts[k] = getattr(self, k)
|
||||
for k in ('mockdir', 'topdir', 'topurl', 'packager', 'vendor', 'distribution', 'mockhost'):
|
||||
for k in ('mockdir', 'topdir', 'topurl', 'packager', 'vendor', 'distribution', 'mockhost', 'yum_proxy'):
|
||||
if hasattr(self.options, k):
|
||||
opts[k] = getattr(self.options, k)
|
||||
opts['buildroot_id'] = self.id
|
||||
|
|
@ -2927,6 +2927,7 @@ def get_options():
|
|||
'createrepo_update': True,
|
||||
'pkgurl': None,
|
||||
'allowed_scms': '',
|
||||
'yum_proxy': None,
|
||||
'maven_repo_ignore': '*.md5 *.sha1 maven-metadata*.xml _maven.repositories '
|
||||
'resolver-status.properties *.lastUpdated',
|
||||
'failed_buildroot_lifetime' : 3600 * 4,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue