[TOWER] P1: Tunnel watchdog — auto-restart on VPS disconnect #437

Open
opened 2026-04-06 13:23:07 +00:00 by Timmy · 0 comments
Owner

Problem

The reverse tunnel (Mac→VPS port 4000) runs as a bare SSH background process. If it drops, agents on the VPS lose access. Nobody notices until someone tries to connect.

Fix

  1. Wrap the tunnel in a launchd service (like Kimi heartbeat)
  2. Health check: test port 4000 every 30s, restart if closed
  3. Log tunnel state to /tmp/tower-tunnel.log

Acceptance

  • Tunnel auto-runs on Mac boot via launchd
  • Tunnel restarts within 30s of any disconnect
  • Health check detects broken tunnel within 30s
## Problem The reverse tunnel (Mac→VPS port 4000) runs as a bare SSH background process. If it drops, agents on the VPS lose access. Nobody notices until someone tries to connect. ## Fix 1. Wrap the tunnel in a launchd service (like Kimi heartbeat) 2. Health check: test port 4000 every 30s, restart if closed 3. Log tunnel state to /tmp/tower-tunnel.log ## Acceptance - [ ] Tunnel auto-runs on Mac boot via launchd - [ ] Tunnel restarts within 30s of any disconnect - [ ] Health check detects broken tunnel within 30s
Timmy self-assigned this 2026-04-06 13:23:08 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Timmy_Foundation/timmy-home#437