Есть 2 идентичных проекта на NuxtJS, запускаю демона через pm2.
Один стартует отлично, а второй никак не хочет. Не могу понять в чем проблема.
Причем если из консоли сам пускаю в ручную npm run start, все работает отлично.
--- Daemon logs --------------------------------------------
/var/www/yaltaprim/data/.pm2/pm2.log last 20 lines:
PM2 | 2022-07-16T13:53:53: PM2 log: Current arch : x64
PM2 | 2022-07-16T13:53:53: PM2 log: PM2 home : /var/www/yaltaprim/data/.pm2
PM2 | 2022-07-16T13:53:53: PM2 log: PM2 PID file : /var/www/yaltaprim/data/.pm2/pm2.pid
PM2 | 2022-07-16T13:53:53: PM2 log: RPC socket file : /var/www/yaltaprim/data/.pm2/rpc.sock
PM2 | 2022-07-16T13:53:53: PM2 log: BUS socket file : /var/www/yaltaprim/data/.pm2/pub.sock
PM2 | 2022-07-16T13:53:53: PM2 log: Application log path : /var/www/yaltaprim/data/.pm2/logs
PM2 | 2022-07-16T13:53:53: PM2 log: Worker Interval : 30000
PM2 | 2022-07-16T13:53:53: PM2 log: Process dump file : /var/www/yaltaprim/data/.pm2/dump.pm2
PM2 | 2022-07-16T13:53:53: PM2 log: Concurrent actions : 2
PM2 | 2022-07-16T13:53:53: PM2 log: SIGTERM timeout : 1600
PM2 | 2022-07-16T13:53:53: PM2 log: ===============================================================================
PM2 | 2022-07-16T13:53:53: PM2 log: App [Yalta-Prim.ru:0] starting in -fork mode-
PM2 | 2022-07-16T13:53:53: PM2 log: App [Krym-Tavrida.ru:1] starting in -fork mode-
PM2 | 2022-07-16T13:53:53: PM2 log: App [Yalta-Prim.ru:0] online
PM2 | 2022-07-16T13:53:53: PM2 log: App [Krym-Tavrida.ru:1] online
PM2 | 2022-07-16T13:53:53: PM2 error: Error: spawn node ENOENT
PM2 | at Process.ChildProcess._handle.onexit (internal/child_process.js:267:19)
PM2 | at onErrorNT (internal/child_process.js:469:16)
PM2 | at processTicksAndRejections (internal/process/task_queues.js:84:21)
PM2 | 2022-07-16T13:53:53: PM2 error: Cancelling versioning data parsing
Конфиг:
module.exports = {
apps : [
{
name: "Krym-Tavrida.ru",
script: "npm",
args: "run start",
cwd:"./../www/krym-tavrida.ru/front"
},
{
name: "Yalta-Prim.ru",
script: "npm",
args: "run start",
cwd:"./../www/yalta-prim/resources/front",
}
]};