Skip to content
This repository has been archived by the owner. It is now read-only.

behind proxy ERROR : request to https://registry.npmjs.org/ionic failed, reason: write EPROTO 140735795004224:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:../deps/openssl/openssl/ssl/s23_clnt.c:827: #19976

Open
bhumin3i opened this issue Mar 6, 2018 · 7 comments

Comments

Projects
None yet
6 participants
@bhumin3i
Copy link

commented Mar 6, 2018

when I install ionic

sudo npm install -g ionic cordova

nwhp331-pc:~ bhumin$ sudo npm install -g ionic cordova
Password:
npm ERR! code EPROTO
npm ERR! errno EPROTO
npm ERR! request to https://registry.npmjs.org/ionic failed, reason: write EPROTO 140735795004224:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:../deps/openssl/openssl/ssl/s23_clnt.c:827:
npm ERR! 

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/bhumin/.npm/_logs/2018-03-06T11_55_20_366Z-debug.log

FILE : /Users/bhumin/.npm/_logs/2018-03-06T11_55_20_366Z-debug.log

0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/bin/node',
1 verbose cli   '/usr/local/bin/npm',
1 verbose cli   'install',
1 verbose cli   '-g',
1 verbose cli   'ionic',
1 verbose cli   'cordova' ]
2 info using npm@5.6.0
3 info using node@v8.9.4
4 verbose npm-session a5bbf7776fdf7f9b
5 silly install loadCurrentTree
6 silly install readGlobalPackageData
7 silly fetchPackageMetaData error for ionic@latest request to https://registry.npmjs.org/ionic failed, reason: write EPROTO 140735795004224:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:../deps/openssl/openssl/ssl/s23_clnt.c:827:
8 silly fetchPackageMetaData error for cordova@latest request to https://registry.npmjs.org/cordova failed, reason: write EPROTO 140735795004224:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:../deps/openssl/openssl/ssl/s23_clnt.c:827:
9 verbose type system
10 verbose stack FetchError: request to https://registry.npmjs.org/ionic failed, reason: write EPROTO 140735795004224:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:../deps/openssl/openssl/ssl/s23_clnt.c:827:
10 verbose stack
10 verbose stack     at ClientRequest.req.on.err (/usr/local/lib/node_modules/npm/node_modules/pacote/node_modules/make-fetch-happen/node_modules/node-fetch-npm/src/index.js:68:14)
10 verbose stack     at emitOne (events.js:116:13)
10 verbose stack     at ClientRequest.emit (events.js:211:7)
10 verbose stack     at onerror (/usr/local/lib/node_modules/npm/node_modules/pacote/node_modules/make-fetch-happen/node_modules/https-proxy-agent/node_modules/agent-base/index.js:106:9)
10 verbose stack     at callbackError (/usr/local/lib/node_modules/npm/node_modules/pacote/node_modules/make-fetch-happen/node_modules/https-proxy-agent/node_modules/agent-base/index.js:126:5)
10 verbose stack     at <anonymous>
11 verbose cwd /Users/bhumin
12 verbose Darwin 17.4.0
13 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g" "ionic" "cordova"
14 verbose node v8.9.4
15 verbose npm  v5.6.0
16 error code EPROTO
17 error errno EPROTO
18 error request to https://registry.npmjs.org/ionic failed, reason: write EPROTO 140735795004224:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:../deps/openssl/openssl/ssl/s23_clnt.c:827:
19 verbose exit [ 1, true ]

npm config edit

proxy=http://xxxx:xxxx/
https-proxy=https://xxx:xxxx/
registry=http://registry.npmjs.org/

already try

export HTTP_PROXY=http://xxxx:xxxx

NOTES:

https://registry.npmjs.org -> work fine in my browser
{"db_name":"registry","doc_count":818776,"doc_del_count":342,"update_seq":7654004,"purge_seq":0,"compact_running":false,"disk_size":5524369542,"data_size":4389156437,"instance_start_time":"1520336710158654","disk_format_version":6,"committed_update_seq":7654004}

@reggi

This comment has been minimized.

Copy link
Contributor

commented May 10, 2018

I am having this issue too, I'm using docker + npm with a private registry.

@reggi

This comment has been minimized.

Copy link
Contributor

commented May 10, 2018

For some reason I'm only getting this issue if npm install is executed with RUN but not CMD.

@reggi

This comment has been minimized.

Copy link
Contributor

commented May 10, 2018

Hmm, nvm CMD doesn't seem to actually install anything.

@Ayusheetripathy14

This comment has been minimized.

Copy link

commented May 16, 2018

did anyone get a solution? I'm getting that error too when I'm doing npm install. I'm trying it on putty.

@ARJUN78

This comment has been minimized.

Copy link

commented Jun 28, 2018

To load npm modules behind a proxy server you need to type in following commands in the node.js terminal:

npm config set proxy http://proxy.company.com:8080
npm config set https-proxy http://proxy.company.com:8080

@melonetern

This comment has been minimized.

Copy link

commented Jul 9, 2018

@ARJUN78

I tried the following, work neither.
npm config set proxy http://hostid:port
npm config set https-proxy https://hostid:port
and checkout setting, which are as setting.
npm config get proxy
npm config get https-proxy

Still waiting for solution, any more suggestion?

@melonetern

This comment has been minimized.

Copy link

commented Jul 10, 2018

Some how it works.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.