更新.gitignore以排除部署配置文件,删除不再使用的一键部署脚本,优化小程序部署流程,增强文档说明。
This commit is contained in:
19
ecosystem.config.cjs
Normal file
19
ecosystem.config.cjs
Normal file
@@ -0,0 +1,19 @@
|
||||
/**
|
||||
* PM2 配置:用于 standalone 部署的服务器
|
||||
* 启动方式:node server.js(不要用 npm start / next start,standalone 无 next 命令)
|
||||
* 使用:pm2 start ecosystem.config.cjs 或 PORT=3006 pm2 start server.js --name soul
|
||||
*/
|
||||
module.exports = {
|
||||
apps: [
|
||||
{
|
||||
name: 'soul',
|
||||
script: 'server.js',
|
||||
interpreter: 'node',
|
||||
env: {
|
||||
NODE_ENV: 'production',
|
||||
PORT: 3006,
|
||||
},
|
||||
cwd: undefined, // 以当前目录为准,部署时在 /www/wwwroot/soul
|
||||
},
|
||||
],
|
||||
};
|
||||
Reference in New Issue
Block a user