ecosystem.config.js
module.exports = {
apps: [
{
name: 'lai-server',
script: 'server.js',
cwd: __dirname,
instances: 1,
exec_mode: 'fork',
autorestart: true,
max_memory_restart: '512M',
env: {
NODE_ENV: 'development',
PORT: 9820
},
env_production: {
NODE_ENV: 'production',
PORT: 9820
}
}
]
};