Quantcast
Channel: CNode:Node.js专业中文社区
Viewing all articles
Browse latest Browse all 14821

pm2怎么开启harmony模式啊?

$
0
0

刚在根目录下面建了一个process.json文件

{
	"apps":[{
		"name": "koajs",
		"script": "app.js",
		"node_args": "–-harmony",
		"watch": true,
		"log_date_format": "YYYY - MM - DD HH: mm Z"
	}]
}

然后terminal里执行pm2 start process.json 然后浏览器运行发现还是没启动,pm2 logs看了下日志显示

0|koajs    |     throw err;
0|koajs    |     ^
0|koajs    | 
0|koajs    | Error: Cannot find module '/Users/artisan/Program/Koa/–-harmony'
0|koajs    |     at Function.Module._resolveFilename (module.js:472:15)
0|koajs    |     at Function.Module._load (module.js:420:25)
0|koajs    |     at Module.runMain (module.js:607:10)
0|koajs    |     at run (bootstrap_node.js:420:7)
0|koajs    |     at startup (bootstrap_node.js:139:9)
0|koajs    |     at bootstrap_node.js:535:3

什么情况?


Viewing all articles
Browse latest Browse all 14821

Trending Articles