Skip to content

Commit

Permalink
Update ecosystem2.config.js for cluster mode
Browse files Browse the repository at this point in the history
Enables pm2 to have direct access to the app and to control it better.
  • Loading branch information
rvolz authored and TimDaub committed Oct 17, 2024
1 parent acbc280 commit c050cbf
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions ecosystem2.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,12 @@ module.exports = {
apps: [
{
name: "kiwinews",
script: "npm run start",
script: "./src/launch.mjs",
// max_memory_restart: "XXXXM", enable to let pm2 restart the app when reaching the memory limit
env: {
DEBUG: "*attestate*",
NODE_ENV: "production",
NODE_PATH: "./node_modules",
THEME: "kiwi",
HTTP_PORT: 3000,
API_PORT: 8443,
Expand All @@ -17,7 +19,7 @@ module.exports = {
USE_EPHEMERAL_ID: false,
},
time: true,
node_args: "--max-old-space-size=12288",
node_args: "-r dotenv/config --max-old-space-size=12288",
},
],
};

0 comments on commit c050cbf

Please sign in to comment.