首页 > 解决方案 > 在 pm2 配置中启动多个脚本

问题描述

请帮我在 pm2 配置中运行这个脚本

"scripts": {
 "start": "export NODE_ENV=production; npm run tsc:build && node -r dotenv/config dist/src/index.js",
}

tsc:build====npm run clean && node_modules/.bin/tsc

它只是进行打字稿编译。

我需要在配置中运行它:

apps: [{
            name: 'my-app',
            script: '????',
            args: '?????',
}]

谢谢你的帮助 :)

标签: node.jspm2

解决方案


推荐阅读