简体   繁体   English

Heroku:应用程序崩溃并部署了“ surespot” Web服务器

[英]Heroku : App crashing with deployment of 'surespot' web-server

I am trying to deploy opensource project 'SureSpot' as a heroku app to experiment with it for research purposes. 我正在尝试将开源项目“ SureSpot”部署为heroku应用,以进行研究以进行研究。 The github link is : https://github.com/surespot/web-server and its written in CoffeeScript running on NodeJs server. github链接是: https : //github.com/surespot/web-server ,它是用在NodeJs服务器上运行的CoffeeScript编写的。 The databases used are Cassandra and Redis. 使用的数据库是Cassandra和Redis。

I am a beginner to NodeJs, CoffeeScript and Heroku as well but tried to get a good grasp before initiating. 我也是NodeJ,CoffeeScript和Heroku的初学者,但是在开始之前尝试了很好的掌握。 I would request someone with good experience of CoffeeScript to look the main code and then the log (shown below) to tell what can be the issue. 我要求具有CoffeeScript经验的人查看主要代码,然后查看日志(如下所示)以说明可能是问题所在。 This project looks different because it doesn't have the app.coffee file while error is "app.js not found" also it doesn't have Procfile. 这个项目看起来与众不同,因为它没有app.coffee文件,而错误是“找不到app.js”,也没有Procfile。

Log :- 日志:-


2014-02-23T13:57:57+00:00 heroku[slug-compiler]: Slug compilation finished 2014-02-23T13:58:10.217762+00:00 app[web.1]: > surespot@0.0.1 start /app 2014-02-23T13:58:10.248303+00:00 app[web.1]: npm ERR! 2014-02-23T13:57:57 + 00:00 heroku [slug-compiler]:Slug编译完成2014-02-23T13:58:10.217762 + 00:00 app [web.1]:> surespot@0.0.1开始/ app 2014-02-23T13:58:10.248303 + 00:00 app [web.1]:npm错误! /app/npm-debug.log 2014-02-23T13:58:10.217765+00:00 app[web.1]: > app.js 2014-02-23T13:58:10.235175+00:00 app[web.1]: sh: app.js: not found 2014-02-23T13:58:10.244028+00:00 app[web.1]: npm ERR! /app/npm-debug.log 2014-02-23T13:58:10.217765 + 00:00 app [web.1]:> app.js 2014-02-23T13:58:10.235175 + 00:00 app [web.1 ]:sh:app.js:找不到2014-02-23T13:58:10.244028 + 00:00 app [web.1]:npm错误! surespot@0.0.1 start: app.js 2014-02-23T13:58:10.244094+00:00 app[web.1]: npm ERR! surespot@0.0.1开始: app.js 2014-02-23T13:58:10.244094 + 00:00 app [web.1]:npm错误! Exit status 127 2014-02-23T13:58:10.248197+00:00 app[web.1]: npm ERR! 退出状态127 2014-02-23T13:58:10.248197 + 00:00 app [web.1]:npm ERR! Additional logging details can be found in: 2014-02-23T13:58:10.244903+00:00 app[web.1]: npm ERR! 其他日志记录详细信息可以在以下位置找到:2014-02-23T13:58:10.244903 + 00:00 app [web.1]:npm ERR! This is most likely a problem with the surespot package, 2014-02-23T13:58:10.244236+00:00 app[web.1]: npm ERR! surespot套件最有可能是这个问题,2014-02-23T13:58:10.244236 + 00:00 app [web.1]:npm ERR! 2014-02-23T13:58:10.244330+00:00 app[web.1]: npm ERR! 2014-02-23T13:58:10.244330 + 00:00 app [web.1]:npm错误! Failed at the surespot@0.0.1 start script. 在surespot@0.0.1启动脚本处失败。 2014-02-23T13:58:10.245091+00:00 app[web.1]: npm ERR! 2014-02-23T13:58:10.245091 + 00:00 app [web.1]:npm错误! not with npm itself. 不与npm本身。 2014-02-23T13:58:10.245276+00:00 app[web.1]: npm ERR! 2014-02-23T13:58:10.245276 + 00:00 app [web.1]:npm错误! Tell the author that this fails on your system: 告诉作者这在您的系统上失败:

2014-02-23T13:58:11.583912+00:00 heroku[web.1]: Process exited with status 1 2014-02-23T13:58:11.592310+00:00 heroku[web.1]: State changed from starting to crashed 2014-02-23T13:58:52.453695+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/ host=testapp1.herokuapp.com request_id=88ea034e-7630-4303-8973-8bda32a94ec6 fwd="138.246.2.71" dyno= connect= service= status=503 bytes= 2014-02-23T13:58:11.583912 + 00:00 heroku [web.1]:进程退出,状态为1 2014-02-23T13:58:11.592310 + 00:00 heroku [web.1]:状态从开始更改为崩溃2014-02-23T13:58:52.453695 + 00:00 heroku [router]:at =错误代码= H10 desc =“ App崩溃”方法=获取路径= / host = testapp1.herokuapp.com request_id = 88ea034e-7630- 4303-8973-8bda32a94ec6 fwd =“ 138.246.2.71” dyno = connect =服务=状态= 503字节=


The package.json file : https://github.com/surespot/web-server/blob/master/package.json states package.json文件: https : //github.com/surespot/web-server/blob/master/package.json指出

"scripts": {
"start": "app.js"

}, },

so maybe thats why it is looking for app.js. 所以也许这就是为什么它正在寻找app.js。

Any kind of help is highly appreciated. 任何帮助都将受到高度赞赏。

Regards, 问候,

Wahib 瓦希卜

You're correct that the package.json has incorrect info. 您是正确的,即package.json的信息不正确。 You need to run it by invoking "server/cluster.coffee". 您需要通过调用“ server / cluster.coffee”来运行它。 You can create a Procfile to do that. 您可以创建一个Procfile来做到这一点。 However, you also need to set a variety of environment variables. 但是,您还需要设置各种环境变量。 I would recommend trying to get it running correctly on your local machine first before deploying to Heroku. 我建议先尝试使其首先在本地计算机上正确运行,然后再部署到Heroku。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM