fix(notifications): use real server name in remote threshold alerts#58
Open
AminDhouib wants to merge 2 commits into
Open
fix(notifications): use real server name in remote threshold alerts#58AminDhouib wants to merge 2 commits into
AminDhouib wants to merge 2 commits into
Conversation
Server CPU/Memory threshold notifications for remote servers always showed "Server Name: Remote" instead of the actual server name, making it impossible to tell which server triggered the alert when more than one remote server is registered. The remote branch of receiveNotification already fetches the matching server row (looked up by its metrics token) but discarded it, hardcoding ServerName to the literal "Remote". Use the fetched row's name instead, falling back to "Remote" if it is somehow absent. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> (cherry picked from commit e19dd43)
This was referenced Jul 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Server CPU/Memory threshold notifications for remote servers always rendered
Server Name: Remote, making alerts indistinguishable when multiple remote servers are registered. The remote branch ofnotification.receiveNotificationalready fetches the matching server row by metrics token but discarded its name. This uses the fetched row's real name, falling back to"Remote"only if absent:All channels (Telegram/Discord/Slack/etc.) share the same
payload.ServerName, so all are fixed by this one line. The Dokploy web-server branch is unaffected.Ports Dokploy#4791 by @PixelPerfector (authorship preserved via cherry-pick).
No issues are closed by this change. The upstream PR body explicitly states no issue reports this exact bug and that Dokploy#3589 is only related (it concerns the server restart notification, a separate notification/feature request) — so Dokploy#3589 is intentionally not listed as addressed here.
Adaptations
None — clean cherry-pick of upstream commit
e19dd43onto canary.Verification
pnpm --filter=dokploy run typecheck— pass (also proves.nameexists on the selected server row type)