fix: keep host name in WinRM update log titles (0.5.17)

Do not overwrite UI log titles with generic backend job.title when several logs are open.
This commit is contained in:
PTah
2026-07-14 10:30:13 +10:00
parent 9883e6aab3
commit f40aa538b0
6 changed files with 28 additions and 12 deletions
+6 -4
View File
@@ -590,7 +590,8 @@ def update_host_agent_via_ssh(
detail="Linux SSH admin is not configured (host override or Settings → Linux)",
)
title = "Обновление ssh-monitor (SSH)"
host_label = (host.display_name or host.hostname or "").strip() or f"host#{host.id}"
title = f"Обновление ssh-monitor (SSH): {host_label}"
try:
start_host_remote_action(
db,
@@ -650,12 +651,13 @@ def post_agent_update_fallback(
from app.services.winrm_connect import is_windows_host
product = (host.product or "").strip()
host_label = (host.display_name or host.hostname or "").strip() or f"host#{host.id}"
if product == PRODUCT_RDP or is_windows_host(host):
title = "Обновление через WinRM"
title = f"Обновление {host_label} через WinRM"
elif product == PRODUCT_SSH or is_linux_host(host):
title = "Fallback SSH (ssh-monitor)"
title = f"Fallback SSH (ssh-monitor): {host_label}"
else:
title = "Обновление агента (fallback)"
title = f"Обновление агента (fallback): {host_label}"
try:
start_host_remote_action(