Add noproxy configuration #6

Closed
wants to merge 1 commit into
from

Projects

None yet

2 participants

vvision commented Oct 12, 2012

no-proxy will have the value of env variables no_proxy or NO_PROXY.

This is an addition to this pull request.

Owner
isaacs commented Oct 12, 2012

What is the goal here? I don't get it.

vvision commented Oct 12, 2012

The goal is to avoid having to set the value of no-proxy with npm config set no-proxy="example.org", if you already have it in your env configuration.

Owner
isaacs commented Oct 12, 2012

What is "no-proxy"? I don't get it. There's no config by that name.
There's a config called "proxy", and you can set that in the environment
as npm_config_proxy=http://user@example.org

You can already set any npm configuration by setting an environment
variable like npm_config_$key=$val

On Fri, Oct 12, 2012 at 9:05 AM, Victor Voisin notifications@github.comwrote:

The goal is to avoid having to set the value of no-proxy with npm config
set no-proxy="example.org"
, if you already have it in your env
configuration.


Reply to this email directly or view it on GitHubhttps://github.com/isaacs/npmconf/pull/6#issuecomment-9381413.

vvision commented Oct 15, 2012

"no-proxy" is a string containing hostnames. When fetching a package from one of these hostnames, the specifed proxy should not be used. In fact if we have a proxy set, since all requests use the proxy, we're unable to fetch packages from a local source which is pretty annoying.
So with no-proxy set, we're able to easily fetch all our packages.

Owner
isaacs commented Oct 15, 2012

Ok, now we're getting at the actual request here. Lovely!

So, you need a way to specify a list of hostnames that will not ever go through a proxy. That's a bit more involved than just adding a config, and the config name cannot start with "no-", because nopt will interpret --no-proxy foo as --proxy=false foo.

I'm closing this pull request, because it's the incorrect approach. Can you please post your request as an issue at https://github.com/isaacs/npm/issues? Thanks.

@isaacs isaacs closed this Oct 15, 2012
vvision commented Oct 16, 2012

Ok, should have explained this in my first post.

In fact, I've already opened an issue a few days ago: npm/npm#2873.
It contains a bit of code which solves the problem.

@vvision vvision referenced this pull request in npm/npm Dec 18, 2012
Closed

Add noproxy configuration #2873

vvision commented Dec 18, 2012

Hum, commit where no-proxy is renamed into noproxy is not taken into account here.

@vvision vvision referenced this pull request in npm/npm-registry-client Dec 18, 2012
Closed

Add noproxy configuration #11

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment