Three improvements for the Clawdie ISO first-boot desktop: 1. Panel health indicator (xfce4-genmon) - polls colibri socket every 30s - green/red dot + agent count + task count - click to open colibri status in terminal 2. Identity wallpaper generator - overlays hostname, Tailscale IP, Colibri port, FreeBSD release - runs on first boot, caches result - requires ImageMagick (add to ISO pkg list) 3. Join Hive launcher - one-click agent registration in visible terminal - checks daemon → vault creds → detect capabilities → register - idempotent, safe to re-run - pauses on result so operator reads before closing All three scripts + skill.md + desktop entry in skills/iso-visuals/.
32 lines
1.4 KiB
Bash
Executable file
32 lines
1.4 KiB
Bash
Executable file
#!/bin/sh
|
|
# xfce4-genmon panel indicator — polls colibri daemon health.
|
|
# Install: add a Generic Monitor panel item pointing to this script.
|
|
# Refresh interval: 30s.
|
|
#
|
|
# Output: green/red dot + agent count + task count.
|
|
# 🟢 2 agents · 3 tasks
|
|
# 🔴 daemon down
|
|
|
|
SOCKET="${COLIBRI_SOCKET:-/var/run/colibri/colibri.sock}"
|
|
TOOLTIP=""
|
|
|
|
if [ -S "$SOCKET" ]; then
|
|
STATUS=$(printf '{"cmd":"status"}\n' | nc -U "$SOCKET" -w 2 2>/dev/null)
|
|
if [ -n "$STATUS" ]; then
|
|
AGENTS=$(echo "$STATUS" | python3 -c "import sys,json; d=json.load(sys.stdin)['data']; print(d['agents'])" 2>/dev/null)
|
|
TASKS=$(echo "$STATUS" | python3 -c "import sys,json; d=json.load(sys.stdin)['data']; t=d['tasks']; print(t['started'])" 2>/dev/null)
|
|
HOST=$(echo "$STATUS" | python3 -c "import sys,json; print(json.load(sys.stdin)['data']['host'])" 2>/dev/null)
|
|
|
|
echo "<txt>🟢 ${AGENTS} agents · ${TASKS} tasks</txt>"
|
|
TOOLTIP="Colibri: ${HOST} | socket: ${SOCKET} | agents: ${AGENTS} | started tasks: ${TASKS}"
|
|
else
|
|
echo "<txt>🔴 no response</txt>"
|
|
TOOLTIP="Colibri socket exists but not responding"
|
|
fi
|
|
else
|
|
echo "<txt>🔴 down</txt>"
|
|
TOOLTIP="Colibri daemon not running (no socket at ${SOCKET})"
|
|
fi
|
|
|
|
echo "<tool>${TOOLTIP}</tool>"
|
|
echo "<txtclick>xfce4-terminal --title 'Colibri Status' --command 'colibri status'</txtclick>"
|