提交 648f0c82 编写于 作者: H Heiss 提交者: Sijie Guo

requests should respect no_proxy env variable (#4867)

If you want to specify a no_proxy variable in your dockerfile or docker-compose.yml, then this little fix respects the variable in get-requests. Otherwise the proxies could break your docker namespace lookup.
上级 2069f761
......@@ -461,7 +461,7 @@ if __name__ == "__main__":
logger.info(http_headers)
global http_proxyes
http_proxyes = {}
http_proxyes = { "no_proxy": os.getenv("NO_PROXY", "") }
if args.proxy:
http_proxyes['http'] = args.proxy
http_proxyes['https'] = args.proxy
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册