【问题标题】:Can't push my node.js app to Heroku无法将我的 node.js 应用程序推送到 Heroku
【发布时间】:2014-08-05 03:17:29
【问题描述】:

我似乎无法将更新后的存储库推送到 Heroku。它以前可以运行,并且该应用现在已在 Heroku 上运行,但我无法向其推送更新。

我已经尝试过 npm 更新、bower 更新、重新安装 Heroku-toolbelt、在不同的网络上推送、从 heroku master 拉取并强制推送到 heroku master、git pull --rebase、npm cache clean、bower cache clean ,卸载业力,更新heroku上的npm并清理heroku上的缓存。

我有多个使用 Heroku 帐户 (https://github.com/ddollar/heroku-accounts) 管理的 Heroku 帐户以及多个 git 帐户,但我确保我使用的是正确的帐户。

这是在推送失败之前来自终端的最后几行:

3530 verbose rebuildBundles   'npmconf',
3530 verbose rebuildBundles   'rimraf',
3530 verbose rebuildBundles   'which' ]
3531 info install phantomjs@1.9.7-5
3532 verbose unsafe-perm in lifecycle true
3533 info phantomjs@1.9.7-5 Failed to exec install script
3534 error phantomjs@1.9.7-5 install: `node install.js`
3534 error Exit status 1
3535 error Failed at the phantomjs@1.9.7-5 install script.
3535 error This is most likely a problem with the phantomjs package,
3535 error not with npm itself.
3535 error Tell the author that this fails on your system:
33535 error     node install.js
3535 error You can get their info via:
3535 error     npm owner ls phantomjs
3535 error There is likely additional logging output above.
3536 error System Linux 3.8.11-ec2
3537 error command "/tmp/build_4600dbd4-687a-4b9c-bf9a-71e3baf5a1c4/vendor/node/bin/node" "/tmp/build_4600dbd4-687a-4b9c-bf9a-71e3baf5a1c4/vendor/node/bin/npm" "rebuild"
3538 error cwd /tmp/build_4600dbd4-687a-4b9c-bf9a-71e3baf5a1c4
3539 error node -v v0.10.29
3540 error npm -v 1.4.14
3541 error code ELIFECYCLE
3542 verbose exit [ 1, true ]

 !     Push rejected, failed to compile Node.js app

To git@heroku.personal:myapp.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'git@heroku.personal:myapp.git'

感谢任何帮助。谢谢!

【问题讨论】:

  • 已经有一段时间了,没有人评论或询问更多信息。所以我在这里有点不知所措。有谁知道我如何检查日志或任何内容以获取有关错误的更多信息?

标签: node.js heroku express


【解决方案1】:

在 StackOverflow 上没有得到任何答案后,我在 Heroku 支持上发布了我的问题。 问题来自 phantomjs,我将其从依赖项中删除并将其移至 devDependencies。之后,我使用 heroku-repo 插件 https://github.com/heroku/heroku-repo 清除了我的构建缓存

然后我可以再次推送到 Heroku

【讨论】:

  • 能否链接到您的 Heroku 支持问题?
  • pastebin.com/avizbWg9 我在原始答案中提供了指向 Heroku-repo 插件的链接。我无法链接到它,因为 Heroku 支持对用户来说是私有的,所以这里是对话的粘贴箱
猜你喜欢
  • 1970-01-01
  • 2016-05-26
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2017-01-31
  • 2018-12-12
  • 2016-05-12
  • 1970-01-01
相关资源
最近更新 更多