36 lines
735 B
JavaScript
36 lines
735 B
JavaScript
module.exports = {
|
|
apps: [{
|
|
name: 'ggl-app',
|
|
script: 'start-production.cjs',
|
|
cwd: '/www/wwwroot/ggl',
|
|
instances: 1,
|
|
exec_mode: 'fork',
|
|
env: {
|
|
NODE_ENV: 'production',
|
|
PORT: 4001
|
|
},
|
|
env_production: {
|
|
NODE_ENV: 'production',
|
|
PORT: 4001
|
|
},
|
|
// 日志配置
|
|
log_file: './logs/combined.log',
|
|
out_file: './logs/out.log',
|
|
error_file: './logs/error.log',
|
|
log_date_format: 'YYYY-MM-DD HH:mm:ss Z',
|
|
|
|
// 进程管理配置
|
|
autorestart: true,
|
|
watch: false,
|
|
max_memory_restart: '1G',
|
|
|
|
// 启动配置
|
|
min_uptime: '10s',
|
|
max_restarts: 10,
|
|
restart_delay: 4000,
|
|
|
|
// 其他配置
|
|
merge_logs: true,
|
|
time: true
|
|
}]
|
|
}; |