安装socket.io

时间:2015-10-31 20:08:08

标签: node.js sockets

我正在尝试在debian上安装socket.io并运行eBot for CS:GO,但是我尝试了一切我发现并且在运行" npm install socket.io"时仍然出错。我包括终端的输出。任何想法如何解决它?当我尝试运行eBot时,它说Websocket服务器崩溃了。

root@debian:/home/ebotv3/ebot-csgo# npm install socket.io
npm http GET http://registry.npmjs.org/socket.io
npm http 304 http://registry.npmjs.org/socket.io
npm http GET http://registry.npmjs.org/engine.io/1.5.4
npm http GET http://registry.npmjs.org/socket.io-parser/2.2.4
npm http GET http://registry.npmjs.org/socket.io-client/1.3.7
npm http GET http://registry.npmjs.org/socket.io-adapter/0.3.1
npm http GET http://registry.npmjs.org/has-binary-data/0.1.3
npm http GET http://registry.npmjs.org/debug/2.1.0
npm http 304 http://registry.npmjs.org/engine.io/1.5.4
npm http 304 http://registry.npmjs.org/socket.io-parser/2.2.4
npm http 304 http://registry.npmjs.org/debug/2.1.0
npm http 304 http://registry.npmjs.org/socket.io-client/1.3.7
npm http 304 http://registry.npmjs.org/socket.io-adapter/0.3.1
npm http 304 http://registry.npmjs.org/has-binary-data/0.1.3
npm http GET http://registry.npmjs.org/debug/1.0.2
npm http GET http://registry.npmjs.org/socket.io-parser/2.2.2
npm http GET http://registry.npmjs.org/object-keys/1.0.1
npm http GET http://registry.npmjs.org/ms/0.6.2
npm http GET http://registry.npmjs.org/isarray/0.0.1
npm http GET http://registry.npmjs.org/ws/0.8.0
npm http GET http://registry.npmjs.org/base64id/0.1.0
npm http GET http://registry.npmjs.org/debug/1.0.3
npm http GET http://registry.npmjs.org/engine.io-parser/1.2.2
npm http GET http://registry.npmjs.org/component-bind/1.0.0
npm http GET http://registry.npmjs.org/component-emitter/1.1.2
npm http GET http://registry.npmjs.org/object-component/0.0.3
npm http GET http://registry.npmjs.org/backo2/1.0.2
npm http GET http://registry.npmjs.org/has-binary/0.1.6
npm http GET http://registry.npmjs.org/parseuri/0.0.2
npm http GET http://registry.npmjs.org/to-array/0.1.3
npm http GET http://registry.npmjs.org/indexof/0.0.1
npm http GET http://registry.npmjs.org/debug/0.7.4
npm http GET http://registry.npmjs.org/engine.io-client/1.5.4
npm http 304 http://registry.npmjs.org/debug/1.0.2
npm http 304 http://registry.npmjs.org/socket.io-parser/2.2.2
npm http GET http://registry.npmjs.org/json3/3.2.6
npm http GET http://registry.npmjs.org/benchmark/1.0.0
npm http 304 http://registry.npmjs.org/ws/0.8.0
npm http 304 http://registry.npmjs.org/ms/0.6.2
npm http 304 http://registry.npmjs.org/base64id/0.1.0
npm http 304 http://registry.npmjs.org/engine.io-parser/1.2.2
npm http 304 http://registry.npmjs.org/debug/1.0.3
npm http GET http://registry.npmjs.org/ms/0.6.2
npm http 304 http://registry.npmjs.org/component-emitter/1.1.2
npm http GET http://registry.npmjs.org/utf8/2.1.0
npm http GET http://registry.npmjs.org/blob/0.0.4
npm http GET http://registry.npmjs.org/after/0.8.1
npm http GET http://registry.npmjs.org/arraybuffer.slice/0.0.6
npm http GET http://registry.npmjs.org/base64-arraybuffer/0.1.2
npm http GET http://registry.npmjs.org/options
npm http GET http://registry.npmjs.org/ultron
npm http GET http://registry.npmjs.org/bufferutil
npm http GET http://registry.npmjs.org/utf-8-validate
npm http 304 http://registry.npmjs.org/component-bind/1.0.0
npm http 304 http://registry.npmjs.org/object-component/0.0.3
npm http 304 http://registry.npmjs.org/object-keys/1.0.1
npm http GET http://registry.npmjs.org/component-emitter/1.1.2
npm http 304 http://registry.npmjs.org/has-binary/0.1.6
npm http 304 http://registry.npmjs.org/parseuri/0.0.2
npm http 304 http://registry.npmjs.org/isarray/0.0.1
npm http 304 http://registry.npmjs.org/debug/0.7.4
npm http 304 http://registry.npmjs.org/indexof/0.0.1
npm http 304 http://registry.npmjs.org/to-array/0.1.3
npm http 304 http://registry.npmjs.org/engine.io-client/1.5.4
npm http 304 http://registry.npmjs.org/ms/0.6.2
npm http 304 http://registry.npmjs.org/backo2/1.0.2
npm http GET http://registry.npmjs.org/better-assert
npm http 304 http://registry.npmjs.org/blob/0.0.4
npm http GET http://registry.npmjs.org/isarray/0.0.1
npm http 304 http://registry.npmjs.org/benchmark/1.0.0
npm http GET http://registry.npmjs.org/component-inherit/0.0.3
npm http GET http://registry.npmjs.org/debug/1.0.4
npm http GET http://registry.npmjs.org/engine.io-parser/1.2.2
npm http GET http://registry.npmjs.org/has-cors/1.0.3
npm http GET http://registry.npmjs.org/parsejson/0.0.1
npm http GET http://registry.npmjs.org/parseqs/0.0.2
npm http GET http://registry.npmjs.org/ws/0.8.0
npm http GET http://registry.npmjs.org/parseuri/0.0.4
npm http GET https://github.com/rase-/node-XMLHttpRequest/archive/a6b6f2.tar.gz
npm http 304 http://registry.npmjs.org/utf8/2.1.0
npm http 304 http://registry.npmjs.org/arraybuffer.slice/0.0.6
npm http 304 http://registry.npmjs.org/after/0.8.1
npm http 304 http://registry.npmjs.org/json3/3.2.6
npm http 304 http://registry.npmjs.org/options
npm http 304 http://registry.npmjs.org/ultron
npm http 304 http://registry.npmjs.org/bufferutil
npm http 304 http://registry.npmjs.org/utf-8-validate
npm http 304 http://registry.npmjs.org/isarray/0.0.1
npm http GET http://registry.npmjs.org/bindings
npm http GET http://registry.npmjs.org/nan
npm http 304 http://registry.npmjs.org/better-assert
npm http 304 http://registry.npmjs.org/component-emitter/1.1.2
npm http 304 http://registry.npmjs.org/debug/1.0.4
npm http GET http://registry.npmjs.org/callsite/1.0.0
npm http 304 http://registry.npmjs.org/component-inherit/0.0.3
npm http 304 http://registry.npmjs.org/parsejson/0.0.1
npm http 304 http://registry.npmjs.org/engine.io-parser/1.2.2
npm http 304 http://registry.npmjs.org/ws/0.8.0
npm http 304 http://registry.npmjs.org/has-cors/1.0.3
npm http 304 http://registry.npmjs.org/parseqs/0.0.2
npm http 200 https://github.com/rase-/node-XMLHttpRequest/archive/a6b6f2.tar.gz
npm http 304 http://registry.npmjs.org/base64-arraybuffer/0.1.2
npm http 304 http://registry.npmjs.org/bindings
npm http 304 http://registry.npmjs.org/parseuri/0.0.4
npm http GET http://registry.npmjs.org/isarray/0.0.1
npm http 304 http://registry.npmjs.org/callsite/1.0.0
npm http 304 http://registry.npmjs.org/nan
npm ERR! error installing utf-8-validate@1.2.1
npm ERR! error installing bufferutil@1.2.1
npm ERR! error installing ws@0.8.0
npm ERR! error installing engine.io@1.5.4
npm ERR! error installing socket.io@1.3.7

npm ERR! Error: No compatible version found: nan@'^2.0.5'
npm ERR! Valid install targets:
npm ERR! ["0.3.0-wip","0.3.0-wip2","0.3.0","0.3.1","0.3.2","0.4.0","0.4.1","0.4.2","0.4.3","0.4.4","0.5.0","0.5.1","0.5.2","0.6.0","0.7.0","0.7.1","0.8.0","1.0.0","1.1.0","1.1.1","1.1.2","1.2.0","1.3.0","1.4.0","1.4.1","1.5.0","1.4.2","1.4.3","1.5.1","1.5.2","1.6.0","1.5.3","1.6.1","1.6.2","1.7.0","1.8.0","1.8.1","1.8.2","1.8.3","1.8.4","1.9.0","2.0.0","2.0.1","2.0.2","2.0.3","2.0.4","2.0.5","2.0.6","2.0.7","2.0.8","2.0.9","2.1.0"]
npm ERR!     at installTargetsError (/usr/local/lib/node_modules/npm/lib/cache.js:488:10)
npm ERR!     at /usr/local/lib/node_modules/npm/lib/cache.js:375:15
npm ERR!     at Object.saved [as oncomplete] (/usr/local/lib/node_modules/npm/lib/utils/npm-registry-client/get.js:147:7)
npm ERR! You may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <npm-@googlegroups.com>
npm ERR!
npm ERR! System Linux 3.2.0-4-amd64
npm ERR! command "node" "/usr/local/bin/npm" "install" "socket.io"
npm ERR! cwd /home/ebotv3/ebot-csgo
npm ERR! node -v v0.6.8
npm ERR! npm -v 1.1.0-2
npm ERR! message No compatible version found: nan@'^2.0.5'
npm ERR! message Valid install targets:
npm ERR! message ["0.3.0-wip","0.3.0-wip2","0.3.0","0.3.1","0.3.2","0.4.0","0.4.1","0.4.2","0.4.3","0.4.4","0.5.0","0.5.1","0.5.2","0.6.0","0.7.0","0.7.1","0.8.0","1.0.0","1.1.0","1.1.1","1.1.2","1.2.0","1.3.0","1.4.0","1.4.1","1.5.0","1.4.2","1.4.3","1.5.1","1.5.2","1.6.0","1.5.3","1.6.1","1.6.2","1.7.0","1.8.0","1.8.1","1.8.2","1.8.3","1.8.4","1.9.0","2.0.0","2.0.1","2.0.2","2.0.3","2.0.4","2.0.5","2.0.6","2.0.7","2.0.8","2.0.9","2.1.0"]
npm http GET http://registry.npmjs.org/better-assert
npm http GET https://github.com/component/global/archive/v2.0.1.tar.gz
npm http GET http://registry.npmjs.org/ms/0.6.2
npm http GET http://registry.npmjs.org/after/0.8.1
npm http GET http://registry.npmjs.org/arraybuffer.slice/0.0.6
npm http GET http://registry.npmjs.org/base64-arraybuffer/0.1.2
npm http GET http://registry.npmjs.org/blob/0.0.4
npm http GET http://registry.npmjs.org/utf8/2.1.0
npm http 304 http://registry.npmjs.org/isarray/0.0.1
npm ERR! error installing has-binary@0.1.6
npm ERR! error installing engine.io-parser@1.2.2
npm http GET http://registry.npmjs.org/options
npm http GET http://registry.npmjs.org/ultron
npm http GET http://registry.npmjs.org/bufferutil
npm http GET http://registry.npmjs.org/utf-8-validate
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     /home/ebotv3/ebot-csgo/npm-debug.log
npm not ok

1 个答案:

答案 0 :(得分:0)

您需要升级您的节点版本。 node v0.6真的很旧,不仅是npm的版本你使用的太旧而不支持版本说明符中使用的插入符号(^),但是nan不支持节点v0 .6无论如何。