SSH to the desktop Mac machine via HTTP relay tunnel. Use when the user wants to run commands on the desktop, access desktop files, or interact with the Mac.
Connect to the desktop Mac via the HTTP relay tunnel configured in ~/.ssh/config.
# Run a command on desktop
ssh desktop "command here"
# Interactive examples
ssh desktop "hostname; uname -a"
ssh desktop "ls -la ~/Desktop"
ssh desktop "brew list"
The connection uses an HTTP relay tunnel that works through the sandbox proxy:
[Sandbox] --HTTPS--> [Cloudflare Tunnel] --> [HTTP Relay Server] --> [SSH Server]
CLAUDE_SSH_RELAY_URL GitHub variableCLAUDE_SSH_RELAY_API_KEY GitHub variable~/.ssh/claude_desktop_keyssh_http_relay.py for HTTP tunnelingThe ~/.ssh/config is automatically configured by the post-checkout hook:
Host desktop
HostName localhost
User m1
IdentityFile ~/.ssh/claude_desktop_key
StrictHostKeyChecking no
UserKnownHostsFile /dev/null
ProxyCommand python3 ~/.ssh/ssh_http_relay.py <relay_url> <api_key>
| Task | Command |
|---|---|
| Check connectivity | ssh desktop "echo ok" |
| System info | ssh desktop "uname -a" |
| List files | ssh desktop "ls -la /path" |
| Run script | ssh desktop "bash -s" < local_script.sh |
| Copy to desktop | cat file | ssh desktop "cat > /path/file" |
| Copy from desktop | ssh desktop "cat /path/file" > local_file |
If SSH fails:
curl -s https://m1.gptkids.app/healthls -la ~/.ssh/claude_desktop_keyssh -v desktop "echo test"