[英]Heroku node.js redis deploy error
I'm trying to push my node.js app to Heroku and get the following error: 我正在尝试将我的node.js应用程序推送到Heroku并收到以下错误:
make: *** [all] Error 1 sh: gmake: not found npm ERR! hiredis@0.1.14 preinstall: `make || gmake` npm ERR! `sh "-c" "make || gmake"` failed with 127 npm ERR! npm ERR! Failed at the hiredis@0.1.14 preinstall script. npm ERR! This is most likely a problem with the hiredis package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! make || gmake npm ERR! You can get their info via: npm ERR! npm owner ls hiredis npm ERR! There is likely additional logging output above.
npm ERR! System Linux 2.6.32-343-ec2
npm ERR! command "/tmp/node-node-v052/bin/node" "/tmp/node-npm-8OVn/cli.js" "rebuild"
npm ERR! cwd /tmp/build_z7yxzlw3xyyk
npm ERR! node -v v0.8.7
npm ERR! npm -v 1.1.49
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /tmp/build_z7yxzlw3xyyk/npm-debug.log
npm ERR! not ok code 0
! Failed to rebuild dependencies with npm
! Heroku push rejected, failed to compile Node.js app
Here is my package.json: 这是我的package.json:
{
"name": "myapp"
, "version": "0.0.1"
, "private": true
,"engines": {
"node": "0.8.x",
"npm": "1.1.x"
}
, "dependencies": {
"express": "2.5.8"
, "jade": ">= 0.0.1"
,"ejs" : ">=0.7.1"
,"pg": ">=0.8.2"
,"moment" : ">=1.7.0"
,"async": ">=0.1.22"
,"request": ">=2.10.0"
, "connect-redis": ">= 0.0.1"
, "redis": ">= 0.0.1"
}
}
Adding node_modules
to .gitignore and running git rm -r --cached .
将
node_modules
添加到.gitignore并运行git rm -r --cached .
fixed the problem. 解决了这个问题。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.