正如我試圖把我的應用程序的NodeJS這是工作的罰款就地就近的Heroku,這裏是我在終點站下車:無法重建的依賴與NPM
[email protected]:~/RubymineProjects/nodejs_consumer$ git push heroku master
Counting objects: 1417, done.
Compressing objects: 100% (1195/1195), done.
Writing objects: 100% (1417/1417), 2.02 MiB | 22 KiB/s, done.
Total 1417 (delta 247), reused 0 (delta 0)
-----> Node.js app detected
-----> Resolving engine versions
Using Node.js version: 0.10.6
Using npm version: 1.2.21
-----> Fetching Node.js binaries
-----> Vendoring node into slug
-----> Installing dependencies with npm
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No readme data.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] 'repositories' (plural) Not supported.
npm WARN package.json Please pick one as the 'repository' field
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No readme data.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] 'repositories' (plural) Not supported.
npm WARN package.json Please pick one as the 'repository' field
npm WARN package.json [email protected] No repository field.
> [email protected] install /tmp/build_f86ikz343m5u/node_modules/dnode/node_modules/weak
> node-gyp rebuild
gyp http GET http://nodejs.org/dist/v0.10.6/node-v0.10.6.tar.gz
gyp http 200 http://nodejs.org/dist/v0.10.6/node-v0.10.6.tar.gz
make: Entering directory `/tmp/build_f86ikz343m5u/node_modules/dnode/node_modules/weak/build'
CXX(target) Release/obj.target/weakref/src/weakref.o
SOLINK_MODULE(target) Release/obj.target/weakref.node
SOLINK_MODULE(target) Release/obj.target/weakref.node: Finished
COPY Release/weakref.node
make: Leaving directory `/tmp/build_f86ikz343m5u/node_modules/dnode/node_modules/weak/build'
> [email protected] install /tmp/build_f86ikz343m5u/node_modules/shoe/node_modules/sockjs/node_modules/rbytes
> node-waf configure build
sh: node-waf: not found
npm ERR! weird error 127
npm ERR! not ok code 0
! Failed to rebuild dependencies with npm
! Heroku push rejected, failed to compile Node.js app
To [email protected]:dcaclab-simulator.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to '[email protected]:dcaclab-simulator.git'
這裏是我的package.json文件:
{
"name": "node-example",
"version": "0.0.1",
"dependencies": {
"dnode": "1.0.5",
"shoe": "0.0.10"
},
"engines": {
"node": "0.10.x",
"npm": "1.2.x"
}
}
有什麼想法嗎?
編輯
嘗試使用節點0.8,這裏是我的了:
[email protected]:~/RubymineProjects/nodejs_consumer$ git push heroku master
Counting objects: 1420, done.
Compressing objects: 100% (1198/1198), done.
Writing objects: 100% (1420/1420), 2.02 MiB | 24 KiB/s, done.
Total 1420 (delta 249), reused 0 (delta 0)
-----> Node.js app detected
-----> Resolving engine versions
Using Node.js version: 0.8.23
Using npm version: 1.2.21
-----> Fetching Node.js binaries
-----> Vendoring node into slug
-----> Installing dependencies with npm
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No readme data.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] 'repositories' (plural) Not supported.
npm WARN package.json Please pick one as the 'repository' field
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No readme data.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] No repository field.
npm WARN package.json [email protected] 'repositories' (plural) Not supported.
npm WARN package.json Please pick one as the 'repository' field
> [email protected] install /tmp/build_1uw8vrtz5u7yu/node_modules/dnode/node_modules/weak
> node-gyp rebuild
gyp http GET http://nodejs.org/dist/v0.8.23/node-v0.8.23.tar.gz
gyp http 200 http://nodejs.org/dist/v0.8.23/node-v0.8.23.tar.gz
make: Entering directory `/tmp/build_1uw8vrtz5u7yu/node_modules/dnode/node_modules/weak/build'
CXX(target) Release/obj.target/weakref/src/weakref.o
SOLINK_MODULE(target) Release/obj.target/weakref.node
SOLINK_MODULE(target) Release/obj.target/weakref.node: Finished
COPY Release/weakref.node
make: Leaving directory `/tmp/build_1uw8vrtz5u7yu/node_modules/dnode/node_modules/weak/build'
> [email protected] install /tmp/build_1uw8vrtz5u7yu/node_modules/shoe/node_modules/sockjs/node_modules/rbytes
> node-waf configure build
Checking for program g++ or c++ : /usr/bin/g++
Checking for program cpp : /usr/bin/cpp
Checking for program ar : /usr/bin/ar
Checking for program ranlib : /usr/bin/ranlib
Checking for g++ : ok
Checking for node path : not found
Checking for node prefix : ok /tmp/node-node-Rkll
'configure' finished successfully (0.027s)
Waf: Entering directory `/home/dcaclab/RubymineProjects/nodejs_consumer/node_modules/shoe/node_modules/sockjs/node_modules/rbytes/build'
Waf: Leaving directory `/home/dcaclab/RubymineProjects/nodejs_consumer/node_modules/shoe/node_modules/sockjs/node_modules/rbytes/build'
Traceback (most recent call last):
File "/tmp/node-node-Rkll/bin/node-waf", line 16, in <module>
Scripting.prepare(t, os.getcwd(), VERSION, wafdir)
File "/tmp/node-node-Rkll/bin/../lib/node/wafadmin/Scripting.py", line 145, in prepare
prepare_impl(t, cwd, ver, wafdir)
File "/tmp/node-node-Rkll/bin/../lib/node/wafadmin/Scripting.py", line 135, in prepare_impl
main()
File "/tmp/node-node-Rkll/bin/../lib/node/wafadmin/Scripting.py", line 188, in main
fun(ctx)
File "/tmp/node-node-Rkll/bin/../lib/node/wafadmin/Scripting.py", line 386, in build
return build_impl(bld)
File "/tmp/node-node-Rkll/bin/../lib/node/wafadmin/Scripting.py", line 405, in build_impl
bld.compile()
File "/tmp/node-node-Rkll/bin/../lib/node/wafadmin/Build.py", line 268, in compile
os.chdir(self.bldnode.abspath())
OSError: [Errno 2] No such file or directory: '/home/dcaclab/RubymineProjects/nodejs_consumer/node_modules/shoe/node_modules/sockjs/node_modules/rbytes/build'
npm ERR! weird error 1
npm ERR! not ok code 0
! Failed to rebuild dependencies with npm
! Heroku push rejected, failed to compile Node.js app
To [email protected]ku.com:dcaclab-simulator.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to '[email protected]:dcaclab-simulator.git'
謝謝,基本上我會嘗試節點0.8,以後,我會聯繫作者rbyes更新他們的模塊。 – simo
請參閱上面的編輯 – simo