From 7683dfebb75776cb2275d73a59d4ff79d85f18ee Mon Sep 17 00:00:00 2001 From: Suk Won Choi Date: Tue, 1 Nov 2016 09:40:49 +0000 Subject: [PATCH] joyent/node-docker-registry-client#13 - Add support for no_proxy --- lib/registry-client-v1.js | 2 ++ lib/registry-client-v2.js | 6 +++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/registry-client-v1.js b/lib/registry-client-v1.js index a6c0b7c..253cd22 100644 --- a/lib/registry-client-v1.js +++ b/lib/registry-client-v1.js @@ -144,6 +144,7 @@ function login(opts, cb) { userAgent: opts.userAgent || common.DEFAULT_USERAGENT, agent: opts.agent, proxy: opts.proxy, + noProxy: opts.noProxy, headers: opts.headers, rejectUnauthorized: !opts.insecure }); @@ -330,6 +331,7 @@ function RegistryClientV1(opts) { log: this.log, agent: opts.agent, proxy: opts.proxy, + noProxy: opts.noProxy, rejectUnauthorized: !this.insecure, userAgent: opts.userAgent || common.DEFAULT_USERAGENT }; diff --git a/lib/registry-client-v2.js b/lib/registry-client-v2.js index fc22c1a..1f9d4d4 100644 --- a/lib/registry-client-v2.js +++ b/lib/registry-client-v2.js @@ -202,6 +202,7 @@ function _getToken(opts, cb) { log: log, agent: opts.agent, proxy: opts.proxy, + noProxy: opts.noProxy, rejectUnauthorized: !opts.insecure, userAgent: opts.userAgent || common.DEFAULT_USERAGENT }); @@ -673,7 +674,8 @@ function ping(opts, cb) { userAgent: opts.userAgent || common.DEFAULT_USERAGENT, rejectUnauthorized: rejectUnauthorized, agent: opts.agent, - proxy: opts.proxy + proxy: opts.proxy, + noProxy: opts.noProxy }); var headers = {}; @@ -875,6 +877,7 @@ function login(opts, cb) { log: log, agent: opts.agent, proxy: opts.proxy, + noProxy: opts.noProxy, userAgent: opts.userAgent, insecure: opts.insecure }, function (err, token) { @@ -1037,6 +1040,7 @@ function RegistryClientV2(opts) { log: this.log, agent: opts.agent, proxy: opts.proxy, + noProxy: opts.noProxy, rejectUnauthorized: !this.insecure, userAgent: opts.userAgent || common.DEFAULT_USERAGENT };