Heroku上的流星不起作用

时间:2016-09-11 17:27:33

标签: meteor heroku

我创建了一个简单的Meteor应用程序:

meteor create test-meteor-app
cd test-meteor-app
meteor
流星开始

然后我创建了一个Heroku服务器。

git init
heroku git:remote -a remote-test-meteor-app
git add .
git commit -am "make it better"
git push heroku master

enter image description here

我得到了:

2016-09-11T17:22:59.978392+00:00 heroku[slug-compiler]: Slug compilation started
2016-09-11T17:22:59.978397+00:00 heroku[slug-compiler]: Slug compilation finished
2016-09-11T17:23:00.336281+00:00 heroku[web.1]: State changed from crashed to starting
2016-09-11T17:23:01.911710+00:00 heroku[web.1]: Starting process with command `npm start`
2016-09-11T17:23:04.001360+00:00 heroku[web.1]: Process exited with status 1
2016-09-11T17:23:04.014649+00:00 heroku[web.1]: State changed from starting to crashed
2016-09-11T17:23:04.015767+00:00 heroku[web.1]: State changed from crashed to starting
2016-09-11T17:23:03.941425+00:00 app[web.1]: 
2016-09-11T17:23:03.941445+00:00 app[web.1]: > meteor run
2016-09-11T17:23:03.941445+00:00 app[web.1]: 
2016-09-11T17:23:03.946773+00:00 app[web.1]: sh: 1: meteor: not found
2016-09-11T17:23:03.957464+00:00 app[web.1]: npm ERR! Linux 3.13.0-93-generic
2016-09-11T17:23:03.957967+00:00 app[web.1]: npm ERR! node v5.11.1
2016-09-11T17:23:03.958306+00:00 app[web.1]: npm ERR! npm  v3.8.6
2016-09-11T17:23:03.959375+00:00 app[web.1]: npm ERR! syscall spawn
2016-09-11T17:23:03.959909+00:00 app[web.1]: npm ERR! Failed at the test-meteor-app@ start script 'meteor run'.
2016-09-11T17:23:03.960274+00:00 app[web.1]: npm ERR! not with npm itself.
2016-09-11T17:23:03.960395+00:00 app[web.1]: npm ERR! Tell the author that this fails on your system:
2016-09-11T17:23:03.960517+00:00 app[web.1]: npm ERR!     meteor run
2016-09-11T17:23:03.960618+00:00 app[web.1]: npm ERR! You can get information on how to open an issue for this project with:
2016-09-11T17:23:03.960743+00:00 app[web.1]: npm ERR!     npm bugs test-meteor-app
2016-09-11T17:23:03.960864+00:00 app[web.1]: npm ERR! Or if that isn't available, you can get their info via:
2016-09-11T17:23:03.961118+00:00 app[web.1]: npm ERR!     npm owner ls test-meteor-app
2016-09-11T17:23:03.961242+00:00 app[web.1]: npm ERR! There is likely additional logging output above.
2016-09-11T17:23:03.964862+00:00 app[web.1]: npm ERR! Please include the following file with any support request:
2016-09-11T17:23:05.446417+00:00 heroku[web.1]: Starting process with command `npm start`
2016-09-11T17:23:07.415275+00:00 heroku[web.1]: Process exited with status 1
2016-09-11T17:23:07.447458+00:00 heroku[web.1]: State changed from starting to crashed
2016-09-11T17:23:07.323157+00:00 app[web.1]: 
2016-09-11T17:23:07.323177+00:00 app[web.1]: > meteor run
2016-09-11T17:23:07.323177+00:00 app[web.1]: 
2016-09-11T17:23:07.328685+00:00 app[web.1]: sh: 1: meteor: not found
2016-09-11T17:23:07.333342+00:00 app[web.1]: 
2016-09-11T17:23:07.340269+00:00 app[web.1]: npm ERR! Linux 3.13.0-93-generic
2016-09-11T17:23:07.340769+00:00 app[web.1]: npm ERR! node v5.11.1
2016-09-11T17:23:07.341215+00:00 app[web.1]: npm ERR! npm  v3.8.6
2016-09-11T17:23:07.341469+00:00 app[web.1]: npm ERR! file sh
2016-09-11T17:23:07.341799+00:00 app[web.1]: npm ERR! errno ENOENT
2016-09-11T17:23:07.342058+00:00 app[web.1]: npm ERR! test-meteor-app@ start: `meteor run`
2016-09-11T17:23:07.342157+00:00 app[web.1]: npm ERR! spawn ENOENT
2016-09-11T17:23:07.342292+00:00 app[web.1]: npm ERR! 
2016-09-11T17:23:07.342424+00:00 app[web.1]: npm ERR! Failed at the test-meteor-app@ start script 'meteor run'.
2016-09-11T17:23:07.342651+00:00 app[web.1]: npm ERR! If you do, this is most likely a problem with the test-meteor-app package,
2016-09-11T17:23:07.342758+00:00 app[web.1]: npm ERR! not with npm itself.
2016-09-11T17:23:07.342853+00:00 app[web.1]: npm ERR! Tell the author that this fails on your system:
2016-09-11T17:23:07.343072+00:00 app[web.1]: npm ERR! You can get information on how to open an issue for this project with:
2016-09-11T17:23:07.343180+00:00 app[web.1]: npm ERR!     npm bugs test-meteor-app
2016-09-11T17:23:07.343300+00:00 app[web.1]: npm ERR! Or if that isn't available, you can get their info via:
2016-09-11T17:23:07.343707+00:00 app[web.1]: npm ERR! There is likely additional logging output above.
2016-09-11T17:23:07.346956+00:00 app[web.1]: 
2016-09-11T17:23:07.347262+00:00 app[web.1]: npm ERR!     /app/npm-debug.log

然后我尝试通过浏览器访问远程应用程序并获得503:

  

remote-test-meteor-app.herokuapp.com

2016-09-11T17:26:19.347339+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=remote-test-meteor-app.herokuapp.com request_id=c3ad6369-00f9-4b16-98b8-ec5bb5a6605b fwd="105.186.215.147" dyno= connect= service= status=503 bytes=
2016-09-11T17:26:21.133873+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=remote-test-meteor-app.herokuapp.com request_id=ec8e8ea9-af47-4cf8-9aac-1c897b4b4e70 fwd="105.186.215.147" dyno= connect= service= status=503 bytes=
2016-09-11T17:26:21.436871+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=remote-test-meteor-app.herokuapp.com request_id=81d5cd8e-4164-4588-84fc-b0ffbcde51ad fwd="105.186.215.147" dyno= connect= service= status=503 bytes=

任何想法都赞赏吗?

更新

的package.json

{
  "name": "test-meteor-app",
  "private": true,
  "scripts": {
    "start": "meteor run"
  },
  "dependencies": {
    "meteor-node-stubs": "~0.2.0"
  } 
}

2 个答案:

答案 0 :(得分:1)

您应该尝试使用Meteor buildpack,其中包括Meteor应用程序需要运行的所有系统依赖项(节点,流星二进制等)。

<div class="captioncontainer">
  <div class="leftcontent">
    <h1>핫요가 효능</h1> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a libero quam. Aliquam volutpat vitae sem sed euismod. Donec a congue ipsum, id sollicitudin orci. Donec neque lectus, elementum non sem sit amet, suscipit sollicitudin quam. Fusce molestie
    dictum turpis nec posuere. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Sed ut ex
  </div>
  <div class="rightcontent">
    Etiam venenatis lobortis felis nec euismod. Aliquam erat volutpat. Nullam faucibus elit nec maximus consectetur. Morbi interdum arcu at enim consectetur, tempor sollicitudin quam vehicula. Fusce urna lectus, dapibus maximus nulla vitae, dictum tristique
    justo. Maecenas porta elementum risus sed mollis. Sed tellus ligula, semper at odio ut, accumsan rutrum diam.

  </div>
</div>

有关详细教程,请参阅this博文。

答案 1 :(得分:0)

同样的问题。这是解决方案。您可以使用heroku run meteor restart重新启动heroku存储库,也可以使用此处描述的步骤重新安装应用:https://medium.com/@leonardykris/how-to-run-a-meteor-js-application-on-heroku-in-10-steps-7aceb12de234

我重新安装了应用程序并且可以正常运行

相关问题