Question

When I run bower install, I get the following error:

Request to https://bower.herokuapp.com/packages/jquery failed with ETIMEDOUT, retrying in 1.8s

But when I run the same URL in the address bar of Chrome, I get the json. I don't know why it fails when I do bower install using Windows 7 command shell. I suspect it has got something to do with my workplace's proxy settings.

Anyone?

Was it helpful?

Solution 2

Have you tried something like http_proxy='proxyserver' https_proxy='proxyserver' bower install? (where proxyserver is your proxy)

OTHER TIPS

Try edit .bowerrc

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

Getting error related to proxy when no proxy is configured: May be npm is picking up proxy.

Delete the proxy attribute from npm config and try. Use:

npm config delete proxy

This solved my problem.

You need to set the new registry for bower in .bowerrc:

{
  "registry": "https://registry.bower.io"
}

The old url https://bower.herokuapp.com/ is no more available.

In my case (Win7), this problem was fixed by providing bower with the proxy settings.

As @Robert Moon mentioned in his answer, you can place this settings in the .bowerrc file.

For proxies that require authentication you will need to provide it as follows:

http://domain\username:password@proxyserverurl:port

The back slash is particularly tricky since it needs to be escaped in the .bowerrc file

Example .bowerrc:

{
  "directory": "bower_components",
  "proxy": "http://domain%5Cusername:password@proxyserverurl:port",
  "https-proxy": "http://domain%5Cusername:password@proxyserverurl:port",
  "no-proxy":"localserver.domain.com"
}

The official documentation from Bower that mentions proxy settings:
https://bower.io/docs/config/#bowerrc-specification

I was also stuck with the same error. The following steps fixed the error for me:

  1. Remove any existing proxy: npm config delete proxy

Then set proxy using: npm config set proxy http://<host>:<port>

  1. You may also need to change the proxy settings for git:

    git config --global http.proxy http://<host>:<port>

  2. Now edit the .bowerrc file as described by Robert Moon

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

Prod server build bower well, but the develop server does not build, it is stop with ETIMEDOUT. The error went through when I added:

"timeout": 120000

into .bowerrc.

Info from page https://bower.io/docs/config/ helped me.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top