mirror of
https://github.com/MacRimi/ProxMenux.git
synced 2026-04-18 01:52:20 +00:00
Update notification service
This commit is contained in:
@@ -251,7 +251,7 @@ class TelegramChannel(NotificationChannel):
|
||||
.replace('>', '>'))
|
||||
|
||||
|
||||
# ─── Gotify ──────────────────────────────────────────────────────
|
||||
# ─── Gotify ───────────────────────────────────────<EFBFBD><EFBFBD>──────────────
|
||||
|
||||
class GotifyChannel(NotificationChannel):
|
||||
"""Gotify push notification channel with priority mapping."""
|
||||
|
||||
@@ -217,6 +217,11 @@ class _StartupGraceState:
|
||||
"""Check if startup aggregation has already been processed."""
|
||||
with self._lock:
|
||||
return self._startup_aggregated
|
||||
|
||||
def mark_startup_aggregated(self) -> None:
|
||||
"""Mark startup aggregation as completed without returning VMs."""
|
||||
with self._lock:
|
||||
self._startup_aggregated = True
|
||||
|
||||
|
||||
# ─── Module-level convenience functions ──────────────────────────────────────
|
||||
@@ -264,6 +269,14 @@ def was_startup_aggregated() -> bool:
|
||||
"""Check if startup aggregation has already been processed."""
|
||||
return _state.was_startup_aggregated()
|
||||
|
||||
def mark_startup_aggregated() -> None:
|
||||
"""Mark startup aggregation as completed without processing VMs.
|
||||
|
||||
Use this when skipping startup notification (e.g., service restart
|
||||
instead of real system boot) to prevent future checks.
|
||||
"""
|
||||
_state.mark_startup_aggregated()
|
||||
|
||||
def is_real_system_boot() -> bool:
|
||||
"""
|
||||
Check if this is a real system boot (not just a service restart).
|
||||
|
||||
Reference in New Issue
Block a user