Skip to content

Commit

Permalink
fix pm2 cluster instance
Browse files Browse the repository at this point in the history
  • Loading branch information
Istiopaxx committed Nov 17, 2023
1 parent 9de0f4e commit 0244a21
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion api/ecosystem.config.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
/* eslint-disable @typescript-eslint/no-var-requires */
module.exports = [
{
name: 'app',
script: 'main.js',
exec_mode: 'cluster',
instances: 'max',
instances: Math.max(require('os').cpus().length - 1, 1), // CPU 코어 수에서 1를 뺀 값
},
];

0 comments on commit 0244a21

Please sign in to comment.