]# pm2
/usr/lib/node_modules/pm2/node_modules/chalk/source/index.js:103
...styles,
^^^
SyntaxError: Unexpected token ...
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:549:28)
at Object.Module._extensions..js (module.js:586:10)
at Module.load (module.js:494:32)
at tryModuleLoad (module.js:453:12)
at Function.Module._load (module.js:445:3)
at Module.require (module.js:504:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/lib/node_modules/pm2/constants.js:10:14)
==============================================
npm install pm2 -g
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
=================================================================
root status
=================
npm install n -g
n latest
/usr/local/bin/npm install pm2 -g
======================
pm2 start main.js
pm3 stop main.js
|