From 88680d478ad7fb5439343b8fbc7bf28ea4a20160 Mon Sep 17 00:00:00 2001 From: nmemmert <67961292+nmemmert@users.noreply.github.com> Date: Mon, 15 Dec 2025 14:51:38 -0500 Subject: [PATCH] Add PM2 ecosystem config with timezone support --- .env.example | 3 +++ ecosystem.config.js | 15 +++++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 ecosystem.config.js diff --git a/.env.example b/.env.example index 00d8fa2..ef4b195 100644 --- a/.env.example +++ b/.env.example @@ -17,3 +17,6 @@ WEBHOOK_URL=https://your-webhook-url.com # Monitoring Settings CHECK_INTERVAL=60000 TIMEOUT=5000 + +# Timezone (use IANA timezone name, e.g., America/New_York, America/Chicago, America/Los_Angeles) +TIMEZONE=America/New_York diff --git a/ecosystem.config.js b/ecosystem.config.js new file mode 100644 index 0000000..8c88666 --- /dev/null +++ b/ecosystem.config.js @@ -0,0 +1,15 @@ +module.exports = { + apps: [{ + name: 'resource-monitor', + script: './server/index.js', + instances: 1, + autorestart: true, + watch: false, + max_memory_restart: '1G', + env: { + NODE_ENV: 'production', + PORT: 3001, + TIMEZONE: 'America/New_York' + } + }] +};