MAKRVF
Tether Guardian
Direct lifeline to Tether. SSH into the server from your computer to check status, watch activity, or restart when needed.
Private Management Console
Quick Connect
Copy & run in Terminal
SSH in
ssh -p 2211
One-liner restart
ssh -p 2211 'bash ~/civ/tools/restart-self.sh'
Check sessions
tmux list-sessions
1. Health Check
Verify Tether is alive and the session is active
-
1Open Terminal and connectSSH into Tether's container
ssh -p 2211
You should be dropped into a Linux shell. If you see a password prompt, your SSH key is not set up yet — see Section 5 below. -
2Check for active tmux sessions
tmux list-sessions
-
3Read the resultHealthy — sessions exist
tether-primary-20260312: 1 windows ...
Unhealthy — no sessionsno server running on /tmp/tmux-1000/default
If you see a session starting withtether-primary, Tether is alive and working. The numbers after the name are just timestamps — totally normal. -
4Quick peek at what Tether is doing (without disturbing anything)Read-only snapshot of last 30 lines
SESSION=$(cat /home/aiciv/.current_session 2>/dev/null || echo tether-primary) tmux capture-pane -t $SESSION -p | tail -30
Safe to run anytime. Does not interrupt Tether's work. -
5Disconnect when done
exit
2. Live Monitoring
Watch exactly what Tether is doing in real time
-
1SSH in and find the active session
ssh -p 2211 tmux list-sessions
-
2Attach to the session to watch liveAttach (use the session name from step 1)
SESSION=$(cat /home/aiciv/.current_session) tmux attach -t $SESSION
You are now watching Tether's live terminal. Scroll withCtrl+B [then arrow keys. Pressqto exit scroll mode. -
3Detach safely without disturbing TetherSafe detach shortcut
Ctrl+B then D
Always detach with Ctrl+B then D. Never close the terminal window while attached — that can interrupt Tether's work.
3. Restart Tether
Bring Tether back when unresponsive or stuck
-
1One-liner restart (no need to SSH first)Full restart in one command
ssh -p 2211 'bash ~/civ/tools/restart-self.sh'
-
2Or restart manually from inside the serverSSH in
ssh -p 2211
Run the restart scriptbash ~/civ/tools/restart-self.sh
The script creates a fresh tmux session and launches Claude Code. Tether will send you a Telegram message when back online. -
3Fallback restart (if restart script is missing)Manual restart
tmux new-session -d -s tether-primary -c /home/aiciv tmux send-keys -t tether-primary 'claude --dangerously-skip-permissions' Enter
-
4Wait and verifyThe restart takes approximately 60–90 seconds. You should get a Telegram message from Tether confirming the restart. You can also verify:Confirm new session exists
tmux list-sessions
⚠
Safe to run anytime. The restart script is safe to run even if Tether is mid-session. All memory and data lives in the project directory, not in the process — nothing is lost on restart.
4. Services & Infrastructure
What's running and how to manage it
| Service | Port | Check / Restart |
|---|---|---|
| Portal Server | 8097 | ps aux | grep portal_server |
| Claude Code (Primary) | — | tmux list-sessions |
| Playwright MCP | — | ps aux | grep playwright-mcp |
| Telegram Bot | — | @tether73_bot on Telegram |
Restart the Portal Server
Kill and restart
pkill -f portal_server.py cd /home/aiciv/purebrain_portal && nohup python3 portal_server.py > /tmp/portal.log 2>&1 &
Check Portal Logs
Last 20 lines
tail -20 /tmp/portal.log
Check All Running Processes
List key processes
ps aux | grep -E "claude|portal_server|playwright" | grep -v grep
ℹ
The Portal Server runs on port 8097 and is reverse-proxied to
tethermelanie.ai-civ.com. Claude Code and Playwright MCP auto-start with each tmux session.
5. Quick Reference
Every important detail at a glance
| Fleet Host | 37.27.237.109 |
| SSH user | aiciv |
| SSH port | 2211 |
| Container | aiciv-11 |
| Project root | /home/aiciv |
| CIV root | /home/aiciv/user-civs/tether-melanie |
| Restart script | ~/civ/tools/restart-self.sh |
| Session name pattern | tether-primary-YYYYMMDD-HHMMSS |
| Portal URL | tethermelanie.ai-civ.com |
| Telegram bot | @tether73_bot |
| Detach from tmux | Ctrl+B then D |
6. SSH Key Setup
One-time setup so you never need a password
This is a one-time setup. After this, connecting to Tether is always password-free.
-
1Generate your guardian SSH keyRun in your Terminal
ssh-keygen -t ed25519 -f ~/.ssh/tether_guardian -C "Melanie_guardian_key"
Press Enter twice when asked for a passphrase (leave it empty). -
2Copy your public keyRun in your Terminal
cat ~/.ssh/tether_guardian.pub
Copy the entire output (starts withssh-ed25519). Paste it to Tether in the portal chat — Tether will install it automatically. -
3Test your connectionRun in your Terminal
ssh -i ~/.ssh/tether_guardian -p 2211 -o StrictHostKeyChecking=no "tmux list-sessions"
If you see a tmux session list, you're connected. Tether is alive. -
4Optional: add a Terminal shortcutAdd to ~/.zshrc (Mac) or ~/.bashrc (Linux)
alias tether='ssh -i ~/.ssh/tether_guardian -p 2211 '
Then runsource ~/.zshrc. After that, just typetetherin Terminal to connect instantly.
7. One-Word Terminal Setup
Type one word to connect — no commands to remember
Set up your SSH config so connecting is just
ssh tether — no IP, port, or key flags needed.-
1Open your SSH configMac / Linux
nano ~/.ssh/config
-
2Add this block at the bottomSSH Config Entry
Host tether HostName 37.27.237.109 User aiciv Port 2211 IdentityFile ~/.ssh/tether_guardian StrictHostKeyChecking noSave withCtrl+XthenYthenEnter. -
3That's it. Now just type:Connect
ssh tether
-
4Bonus: one-liner commands without logging inCheck if alive
ssh tether "tmux list-sessions"
Restart Tetherssh tether "bash ~/civ/tools/restart-self.sh"
Quick peek at activityssh tether "SESSION=\$(cat /home/aiciv/.current_session 2>/dev/null || echo tether-primary); tmux capture-pane -t \$SESSION -p | tail -30"
ℹ
With SSH config set up, every command on this page that uses
ssh -p 2211 aiciv@37.27.237.109 can be replaced with just ssh tether.
8. Claude Code Guardian Skill
Let your local Claude check on Tether for you
If you have Claude Code installed locally, you can teach it how to check on and restart Tether. Then you just open Terminal, type
claude, and say "Check on Tether".-
1Install Claude Code (if you haven't already)Mac
brew install claude-code
-
2Create the guardian skill folder
mkdir -p ~/.claude/skills/tether-guardian
-
3Save the skill fileCopy the text below and save it as
~/.claude/skills/tether-guardian/SKILL.mdSKILL.md content# Tether Guardian — Your AiCIV Lifeline When asked to "check on Tether" or "restart Tether": ## Connection Details - Fleet Host: 37.27.237.109 - SSH Port: 2211 - User: aiciv - SSH Key: ~/.ssh/tether_guardian - Tmux Session Prefix: tether-primary ## Check if Tether is alive ```bash ssh -i ~/.ssh/tether_guardian -p 2211 -o StrictHostKeyChecking=no aiciv@37.27.237.109 "tmux list-sessions 2>/dev/null | grep tether-primary || echo DEAD" ``` If output shows tether-primary — Tether is alive. If DEAD — restart needed. ## Restart Tether ```bash ssh -i ~/.ssh/tether_guardian -p 2211 -o StrictHostKeyChecking=no aiciv@37.27.237.109 "bash ~/civ/tools/restart-self.sh" ``` Wait 90 seconds, then verify: ```bash ssh -i ~/.ssh/tether_guardian -p 2211 -o StrictHostKeyChecking=no aiciv@37.27.237.109 "SESSION=\$(cat /home/aiciv/.current_session 2>/dev/null || echo tether-primary); tmux capture-pane -t \$SESSION -p -S -20 2>/dev/null | tail -20" ``` ## Fallback restart ```bash ssh -i ~/.ssh/tether_guardian -p 2211 -o StrictHostKeyChecking=no aiciv@37.27.237.109 \ "tmux new-session -d -s tether-primary -c /home/aiciv && \ tmux send-keys -t tether-primary 'claude --dangerously-skip-permissions' Enter" ``` ## Portal: https://tethermelanie.ai-civ.com
-
4Test itOpen a new terminal, type
claude, then say: "Check on Tether"
ℹ
This skill teaches your local Claude exactly how to reach Tether. You don't need to remember any commands — just ask Claude to check on Tether and it handles everything.