流星束之后,node.js被“侦听".但没有出现在本地主机 [英] After meteor bundle, node.js is "LISTENING" but not showing up at localhost

查看:72
本文介绍了流星束之后,node.js被“侦听".但没有出现在本地主机的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我捆绑了一个流星应用程序,并使用node运行未压缩的tarball.我不确定为什么该应用程序似乎没有出现在本地主机上.这是我的捆绑方式:

I'm bundling a meteor app and running the uncompressed tarball with node. I am not sure why the app doesn't seem to appear on localhost. Here is how I'm bundling:

$ meteor bundle app.tar.gz

然后我解压缩:

$ tar -zxvf app.tar.gz

然后我进入捆绑目录并按照自述文件中的说明进行操作:

Then I cd into the bundle directory and do as the README says:

$ rm -r programs/server/node_modules/fibers
$ npm install fibers@1.0.1
$ export MONGO_URL='mongodb://<dbuser>:<dbpassword>@<PORT>.mongolab.com:<PORT>/<db>'
$ export ROOT_URL='http://localhost:3000'
$ node main.js

然后,节点说它是LISTENING,但是localhost:3000没有连接.

Then, node says it is LISTENING but localhost:3000 doesn't connect.

我有节点v0.10.22,Meteor说bundle仅在节点v0.10.21上进行了测试,但这似乎不太可能是问题所在.我在做错什么吗?

I have node v0.10.22, and Meteor says bundle has only been tested with node v0.10.21, but it seems unlikely to be the problem. Am I doing something wrong?

推荐答案

您还必须指定PORT

export MONGO_URL='mongodb://<dbuser>:<dbpassword>@<PORT>.mongolab.com:<PORT>/<db>'
export ROOT_URL='http://localhost:3000'
export PORT=3000
node main.js

这篇关于流星束之后,node.js被“侦听".但没有出现在本地主机的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆