localhost_oa_based/ecosystem.config.js

23 lines
409 B
JavaScript
Raw Normal View History

2024-02-28 08:32:35 +08:00
const { cpus } = require('os')
const cpuLen = cpus().length
module.exports = {
apps: [
{
2024-02-28 11:53:50 +08:00
name: 'huaxin-admin',
2024-02-28 08:32:35 +08:00
script: './dist/main.js',
autorestart: true,
exec_mode: 'cluster',
watch: false,
instances: cpuLen,
max_memory_restart: '520M',
args: '',
env: {
NODE_ENV: 'production',
PORT: process.env.APP_PORT,
},
},
],
}