20 lines
532 B
JavaScript
20 lines
532 B
JavaScript
/**
|
||
* PM2 配置:用于 standalone 部署的服务器
|
||
* 启动方式:node server.js(不要用 npm start / next start,standalone 无 next 命令)
|
||
* 使用:pm2 start ecosystem.config.cjs 或 PORT=30006 pm2 start server.js --name soul
|
||
*/
|
||
module.exports = {
|
||
apps: [
|
||
{
|
||
name: 'soul',
|
||
script: 'server.js',
|
||
interpreter: 'node',
|
||
env: {
|
||
NODE_ENV: 'production',
|
||
PORT: 30006,
|
||
},
|
||
cwd: undefined, // 以当前目录为准,部署时在 /www/wwwroot/soul
|
||
},
|
||
],
|
||
};
|