Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bower error tunneling socket could not be established, cause=Parse Error

I'm behind a corporate proxy, I've set my HTTP_PROXY and HTTPS_PROXY env var to

http://username:password@proxyname:port/

doing console.log(process.env) output these var correctly. npm is working, I got bower with it and it(bower) was working fine but since I restarted windows XP I'm always getting :

bower error tunneling socket could not be established, cause=Parse Error

I don't think there's anything new on the proxy side. I've already tried reseting those vars, restarting everything... Any sugestion ?

like image 607
user2251745 Avatar asked Jun 26 '13 15:06

user2251745


4 Answers

If changing the proxy settings as pointed out by Vipul is not sufficient also change the registry:

npm config set registry http://registry.npmjs.org/
like image 186
Dunken Avatar answered Nov 15 '22 19:11

Dunken


I really don't know why but clearing an .npmrc file in my home fixed it.

like image 29
user2251745 Avatar answered Nov 15 '22 19:11

user2251745


Following command work for me

npm config set proxy "http://domain\username:password@servername:port/"
like image 40
Vipul R Avatar answered Nov 15 '22 19:11

Vipul R


I was getting the same issue with corporate proxy ON.

The solution is you just need to set system environment variables 'http_proxy' & 'https_proxy' to http://username:password@proxyname:port/

No need to clear .npmrc file.

Its a clear proxy issue and not a node issue. :)

like image 45
Amit Prabhu Parrikar Avatar answered Nov 15 '22 19:11

Amit Prabhu Parrikar