summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Weber <matthew.weber@rockwellcollins.com>2018-07-11 14:31:11 (GMT)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>2018-08-10 20:36:10 (GMT)
commit361bc21c523e0e6f030080eb910dfb53e4614c7b (patch)
treeb02fc6de5f7393fb3f4bff1cca1c6850401e586d
parent01d8a0a9455f9408819d7f135fba5139f0672507 (diff)
downloadbuildroot-361bc21c523e0e6f030080eb910dfb53e4614c7b.tar.gz
buildroot-361bc21c523e0e6f030080eb910dfb53e4614c7b.tar.bz2
support/testing: runtest proxy support
Allow builder.py to inherit the system proxy settings from the env if they are present. Signed-off-by: Matthew Weber <matthew.weber@rockwellcollins.com> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
-rw-r--r--support/testing/infra/builder.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/support/testing/infra/builder.py b/support/testing/infra/builder.py
index faf1eb1..30230fd 100644
--- a/support/testing/infra/builder.py
+++ b/support/testing/infra/builder.py
@@ -35,6 +35,12 @@ class Builder(object):
def build(self):
env = {"PATH": os.environ["PATH"]}
+ if "http_proxy" in os.environ:
+ self.logfile.write("Using system proxy: " +
+ os.environ["http_proxy"] + "\n")
+ self.logfile.flush()
+ env['http_proxy'] = os.environ["http_proxy"]
+ env['https_proxy'] = os.environ["http_proxy"]
cmd = ["make", "-C", self.builddir]
ret = subprocess.call(cmd, stdout=self.logfile, stderr=self.logfile,
env=env)