@irsyadulibad/servermon 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/cli.ts +2 -0
  2. package/package.json +1 -1
package/cli.ts CHANGED
@@ -55,6 +55,7 @@ async function setupSystemd(): Promise<void> {
55
55
  try { await import("node:fs").then(m => m.mkdirSync(systemdDir, { recursive: true })); } catch {}
56
56
 
57
57
  const serviceFile = `${systemdDir}/servermon.service`;
58
+ const bunDir = bunPath.replace(/\/bun$/, ""); // strip binary name, keep directory
58
59
  const serviceContent = `[Unit]
59
60
  Description=Server Monitor — Telegram system health reports
60
61
  After=network-online.target
@@ -66,6 +67,7 @@ ExecStart=${servermonPath} start
66
67
  Restart=always
67
68
  RestartSec=30
68
69
  Environment=NODE_ENV=production
70
+ Environment=PATH=${bunDir}:/usr/local/bin:/usr/bin:/bin
69
71
 
70
72
  [Install]
71
73
  WantedBy=default.target
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@irsyadulibad/servermon",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "description": "Lightweight server monitoring daemon — collects system metrics and sends structured reports to Telegram. Built with Bun + TypeScript.",
5
5
  "module": "index.ts",
6
6
  "type": "module",