diff --git a/compose.yaml b/compose.yaml index 42fb50d65..c06430ff2 100644 --- a/compose.yaml +++ b/compose.yaml @@ -1,7 +1,8 @@ services: uptime-kuma: hostname: uptime-kuma - image: louislam/uptime-kuma:1 + # image: louislam/uptime-kuma:1 + volumes: - ./data:/app/data ports: diff --git a/server/model/monitor.js b/server/model/monitor.js index 92afb5c73..5b10c7c08 100644 --- a/server/model/monitor.js +++ b/server/model/monitor.js @@ -24,7 +24,7 @@ const { CookieJar } = require("tough-cookie"); const { HttpsCookieAgent } = require("http-cookie-agent/http"); const https = require("https"); const http = require("http"); -const os = require('os'); +const os = require("os"); const rootCertificates = rootCertificatesFingerprints(); @@ -1302,6 +1302,8 @@ class Monitor extends BeanModel { // Prevent if the msg is undefined, notifications such as Discord cannot send out. if (!heartbeatJSON["msg"]) { heartbeatJSON["msg"] = "N/A"; + } else { + heartbeatJSON["msg"] = `[${os.hostname()}] ${heartbeatJSON["msg"]}`; } // Also provide the time in server timezone