2017-03-18 26 views
0

ノードとnpmとgulpを学習しようとしていますが、このエラーが発生しています。npm install --save-dev gulp:SELF_SIGNED_CERT_IN_CHAIN

$ npm install --save-dev gulp 
npm ERR! Windows_NT 6.3.9600 
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "--save-dev" "gulp" 
npm ERR! node v6.10.0 
npm ERR! npm v3.10.10 
npm ERR! code SELF_SIGNED_CERT_IN_CHAIN 

npm ERR! self signed certificate in certificate chain 
npm ERR! 
npm ERR! If you need help, you may report this error at: 
npm ERR!  <https://github.com/npm/npm/issues> 

npm ERR! Please include the following file with any support request: 
npm ERR!  C:\Users\davidb\desktop\testproject\npm-debug.log 

これを修正する方法を知っている人はいますか?ノードの代わりにgitbashを使用しています。私のノードではnode-vを実行することもできないため、process.versionを使用してバージョンを取得する必要があります。そしてこれで大いに感謝します!私はhttp://blog.npmjs.org/post/78165272245/more-help-with-selfsignedcertinchain-and-npmを使って問題を解決しようとしていますが、何も問題はありません。

も試してみました:

npm config set ca "" 

and 

npm install npm -g --ca="" 

どちらも働いていると私はまだエラーNPMのERRを取得しています!コードSELF_SIGNED_CERT_IN_CHAIN

答えて

0

多分、WindowsのSSLを代行するプロキシがあなたのnpmを乱しています。

チェックアウトGithubの発行答え - https://github.com/npm/npm/issues/7519#issuecomment-97522305

その他のオプション:

npm config set registry http://registry.npmjs.org/

しかし、これはあなたのセキュリティを低下させます。