如何让nodejs在linux后台运行

加入 主文件是 index.js node

那么能够用的方法有: npm

  1.用forever  进行管理 spa

1
2
npm install -g forever
forever start index.js


2. 用自带的服务nohub ci

1
nohup node index.js > myLog.log 2>&1 &
相关文章
相关标签/搜索