1

我不确定与此类似的问题是否会对我有所帮助。我在这里发布我的问题。

当我从 Git 推送后尝试运行 heroku 应用程序时。我收到应用程序错误。我尝试从 Heroku 日志中理解。但我无法解决。以下是我的heroku日志:

2013-08-22T13:41:39.721111+00:00 heroku[api]: Enable Logplex by venkateshwaran.selvaraj@gmail.com
2013-08-22T13:41:39.740369+00:00 heroku[api]: Release v2 created by venkateshwaran.selvaraj@gmail.com
2013-08-22T13:51:31+00:00 heroku[slug-compiler]: Slug compilation started
2013-08-22T13:51:46.559912+00:00 heroku[api]: Scale to web=1 by venkateshwaran.selvaraj@gmail.com
2013-08-22T13:51:46.584043+00:00 heroku[api]: Add PATH config by venkateshwaran.selvaraj@gmail.com
2013-08-22T13:51:46.600930+00:00 heroku[api]: Release v3 created by venkateshwaran.selvaraj@gmail.com
2013-08-22T13:51:46.646480+00:00 heroku[api]: Deploy 8435747 by venkateshwaran.selvaraj@gmail.com
2013-08-22T13:51:46.670367+00:00 heroku[api]: Release v4 created by venkateshwaran.selvaraj@gmail.com
2013-08-22T13:51:46+00:00 heroku[slug-compiler]: Slug compilation finished
2013-08-22T13:51:50.333471+00:00 heroku[web.1]: Starting process with command `node venkat1.js`
2013-08-22T13:51:51.462059+00:00 app[web.1]: Script: /app/venkat1.js
2013-08-22T13:51:51.462059+00:00 app[web.1]: To: hello.txt
2013-08-22T13:51:51.462059+00:00 app[web.1]: Wrote: A startup is a business built to grow rapidly.
2013-08-22T13:51:52.874576+00:00 heroku[web.1]: State changed from starting to crashed
2013-08-22T13:51:52.876904+00:00 heroku[web.1]: State changed from crashed to starting
2013-08-22T13:51:52.863778+00:00 heroku[web.1]: Process exited with status 0
2013-08-22T13:51:54.448525+00:00 heroku[web.1]: Starting process with command `node venkat1.js`
2013-08-22T13:51:55.205895+00:00 app[web.1]: Script: /app/venkat1.js
2013-08-22T13:51:55.205895+00:00 app[web.1]: Wrote: A startup is a business built to grow rapidly.
2013-08-22T13:51:55.205895+00:00 app[web.1]: To: hello.txt
2013-08-22T13:51:56.510045+00:00 heroku[web.1]: State changed from starting to crashed
2013-08-22T13:51:56.495030+00:00 heroku[web.1]: Process exited with status 0
2013-08-22T13:51:57.488699+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/ host=hidden-caverns-8212.herokuapp.com fwd="182.65.171.54" dyno= connect= service= status=503 bytes=
2013-08-22T13:52:06.605453+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/ host=hidden-caverns-8212.herokuapp.com fwd="182.65.171.54" dyno= connect= service= status=503 bytes=
2013-08-22T13:52:07.142203+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/favicon.ico host=hidden-caverns-8212.herokuapp.com fwd="182.65.171.54" dyno= connect= service= status=503 bytes=

我的文件在Github

4

1 回答 1

0

看起来您正在为 Coursera创业工程课程做作业1 。

该脚本未设置为托管 Web 服务器。您正在运行的代码是在关闭之前将消息写入 hello.txt,这应该可以在您的本地计算机或 AWS 实例上运行。您可以通过检查 hello.txt 文件来查看结果。

Homework 3中,您将获得使用 node.js Express 框架创建 Web 服务器的代码,您可以将其托管在 Heroku 上并使用浏览器访问。

于 2013-08-22T16:06:10.023 回答