fix: rename pm2 worker and invoke tsx directly instead of npm

pm2 fork mode require()s the resolved script rather than spawning a
shell, and on o2switch `npm` resolves to CloudLinux's bash npm_wrapper,
so pm2 crashed instantly (SyntaxError) and restart-looped forever.
Point pm2 at tsx's real ESM entry (node_modules/tsx/dist/cli.mjs)
instead. Also renames the pm2 process to video-downloader-worker.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-08-11 16:21:25 +02:00
co-authored by Claude Sonnet 5
parent fd0bc092bd
commit 771297cdf1
3 changed files with 7 additions and 7 deletions
+2 -2
View File
@@ -16,8 +16,8 @@
"worker:pm2:start": "pm2 start ecosystem.config.cjs",
"worker:pm2:stop": "pm2 stop ecosystem.config.cjs",
"worker:pm2:restart": "pm2 restart ecosystem.config.cjs",
"worker:pm2:status": "pm2 status ombrora-worker",
"worker:pm2:logs": "pm2 logs ombrora-worker",
"worker:pm2:status": "pm2 status video-downloader-worker",
"worker:pm2:logs": "pm2 logs video-downloader-worker",
"db:migrate": "prisma migrate dev",
"db:migrate:deploy": "prisma migrate deploy",
"db:generate": "prisma generate",