[proxy] bower proxy configuration

is there a way to configure bower not only to use a proxy but ignore the proxy configuration for some domains?

I have the problem, that I will run an internal bower registry for our own developed components. For that repository I would like to ignore the proxy configuration.

This question is related to proxy bower

The answer is


create .bowerrc file in you home directory and adding this to the file worked for me

{

 "directory": "bower_components",
 "proxy": "http://youProxy:yourPort",
  "https-proxy":"http://yourProxy:yourPort"
}

add in .bowerrc

{SET HTTP_PROXY= http://HOST:PORT,SET HTTPS_PROXY=http://HOST:PORT}

In NPM, you must to execute in console this:

npm --proxy http://Host:Port install

Are you using Windows? Just set the environment variable http_proxy...

set http_proxy=http://your-proxy-address.com:port

... and bower will pick this up. Rather than dealing with a unique config file in your project folder - right? (side-note: when-the-F! will windows allow us to create a .file using explorer? c'mon windows!)


There is no way to configure an exclusion to the proxy settings, but a colleague of mine had an create solution for that particular problem. He installed a local proxy server called cntlm. That server supports ntlm authentication and exclusions to the general proxy settings. A perfect match.


The key for me was adding an extra line, "strict-ssl": false

Create .bowerrc on root folder, and add the following,

{
  "directory": "bower_components", // If you change this, your folder named will change within dependecies. EX) Vendors instead of bower_components.
  "proxy": "http://yourProxy:yourPort",
  "https-proxy":"http://yourProxy:yourPort",
  "strict-ssl": false 
}

Best of luck for the people still stuck on this.


I had ETIMEDOUT error, and after putting

{
  "proxy":"http://<user>:<password>@<host>:<port>",
  "https-proxy":"http://<user>:<password>@<host>:<port>"
}

just worked. I don't know if you have something wrong in the .bowerrc or ECONNRESET can't be solved with this, but I hope this help you ;)


I struggled with this from behind a proxy so I thought I should post what I did. Below one is worked for me.

-> "export HTTPS_PROXY=(yourproxy)"


Edit your .bowerrc file ( should be next to your bower.json file ) and add the wanted proxy configuration

"proxy":"http://<host>:<port>",
"https-proxy":"http://<host>:<port>"

Add the below entry to your .bowerrc:

{
  "proxy":"http://<user>:<password>@<host>:<port>",
  "https-proxy":"http://<user>:<password>@<host>:<port>"
}

Also if your password contains any special character URL-encode it Eg: replace the @ character with %40


Inside your local project open the .bowerrc that contains:

{
   "directory": "bower_components"
 }

and add the following code-line:

{
   "directory": "bower_components",
  "proxy": "http://yourProxy:yourPort",
  "https-proxy":"http://yourProxy:yourPort"
}

bower version: 1.7.1

Cheers