feat(ntfy): separate C&C topic from message ingestion

- Add ntfy_cc_topic config for command and control
- Add separate NtfyPoller for C&C in StreamController
- Implement serial-port-like interface: commands are executed and responses are sent back to the same topic
- Update cmdline.py to use C&C topic
This commit is contained in:
2026-03-15 17:40:20 -07:00
parent 2f1b2591c6
commit 3324adb07a
3 changed files with 42 additions and 2 deletions

View File

@@ -25,7 +25,12 @@ from engine import config
from engine.effects.controller import handle_effects_command
from engine.terminal import CLR, CURSOR_OFF, CURSOR_ON, G_DIM, G_HI, RST, W_GHOST
TOPIC = config.NTFY_TOPIC
try:
CC_TOPIC = config.NTFY_CC_TOPIC
except AttributeError:
CC_TOPIC = "https://ntfy.sh/klubhaus_terminal_mainline_cc/json"
TOPIC = CC_TOPIC
def send_command(cmd: str) -> str: