我试图设置Meteor使用pm2(https://github.com/Unitech/pm2)而不是永远作为节点进程监视器.我没有幸运获得pm2进程需要看到Meteor应用程序的环境变量.
这是我的过程:
export MONGO_URL="mongodb://localhost:27017/meteor" export PORT=4000 export ROOT_URL="https://beta.example.com/" pm2 start main.js --name MyMeteorApp
在pm2的错误日志中,我看到我的Meteor应用程序抱怨无法找到MONGO_URL
.
为了使用pm2,我需要一个特定的方法来进行导出吗?