Linking environments can't use an SSH route, so SSH-only machines fail to link
What happened
In the desktop app, a machine can be added as an SSH environment, and SSH can be its only route. Agent linking (the link card and t3 environment link) ignores that route. It tries the target's own advertised HTTP addresses (LAN and Tailscale IP), refuses them as "plain http", and fails.
The error also says "or its Tailscale address" while rejecting the Tailscale IP.
Diagnosis
In v0.1.10, peerOrigin in apps/server/src/peer/PeerLinks.ts (lines 155-178) rejects any http: origin unless it is loopback or passes isTailnetHost. isTailnetHost accepts *.ts.net names and Tailscale IPv6 addresses, but not numeric Tailscale IPv4 addresses. That is why both the LAN IP and the Tailscale IP are refused. The message at line 173 still offers "its Tailscale address".
Nothing in this path considers the environment's saved SSH route. I did not trace the link-card candidate selection and did not run a reproduction.
Requested behaviour: linking should be able to run over the SSH route. SSH already encrypts and authenticates the connection. The desktop app already obtains a pairing credential and runs a tunnel over it, so agent links could reuse that. This would remove the need for Tailscale or HTTPS on every machine.
Steps to reproduce
- In the desktop app, add a machine as an SSH environment, with SSH as its only route.
- Open Settings > Linked environments > Link, or run
t3 environment link, for that machine. - The link tries the machine's advertised LAN and Tailscale IP over http and fails with "is plain http, which would send the link's credentials unencrypted".
Version
T3 Code v0.1.10, desktop app. The triage CLI was also 0.1.10.
Environment
Linux x64, desktop app, local server v0.1.10. Machines are reached over SSH.
Evidence
- Source: `apps/server/src/peer/PeerLinks.ts:155-178` and `packages/shared/src/hostClassification.ts` (`isTailnetHost`), at tag v0.1.10.
- Error text: `PeerLinkError: <url> is plain http, which would send the link's credentials unencrypted. Use its https address, or its Tailscale address.`
Related issues
- #26450: the Tailscale IP is picked and then rejected, with an SSH-connected environment.
- #26840: LAN linking is refused because
t3 paironly produces http. - #27678 (closed): http on private networks is refused for links but accepted for client pairing.
- #29585 (closed): managing SSH environments from the CLI.
Fix applied or workaround
Serve each machine over HTTPS (tailscale serve), mint a code on the target with t3 pair, then link with that code and the ts.net URL. This forces a Tailscale dependency.
Filed by
Claude Sonnet 5.5 (claude-sonnet-5-5), through Claude Code running the T3 Code triage playbook
Thanks for writing this up. It asks for new behaviour rather than reporting a defect, so it does not belong in the bug tracker and I'm closing it as not planned here. Feature ideas are discussed in Discussions: please post it there.