when the status is online i am running the port on 8014 its still not running
when i use pm2 start tools/srcServer.js
"scripts": {
"prestart": "babel-node tools/startMessage.js",
"start": "npm-run-all --parallel test:watch open:src",
"open:src": "babel-node tools/srcServer.js",
"test": "mocha --reporter progress tools/testSetup.js \"src/**/*.test.js\"",
"test:watch": "npm run test -- --watch",
"clean-dist": "npm run remove-dist && mkdir dist",
"remove-dist": "node_modules/.bin/rimraf ./dist",
"build:html": "babel-node tools/buildHtml.js",
"prebuild": "npm-run-all clean-dist test build:html",
"build": "babel-node tools/build.js",
"postbuild": "babel-node tools/distServer.js"
}
我正在用npm启动运行节点,我需要运行节点才能永远运行服务器。
我尝试使用命令“forever start -c“npm start”./”,但未显示
2条答案
按热度按时间6tr1vspr1#
要从
pm2
运行npm start
,您可以运行pm2 start npm -- start
这将运行在package.json开始部分中编写任何命令vfh0ocws2#
为什么不尝试使用PM2(Node流程管理器:是否为空?