Open the Tailscale admin console from the panel mark - #9234
Open
cschaba wants to merge 1 commit into
Open
Conversation
Machine management — renaming, key expiry, ACLs, approving a subnet route — all lives in the admin console, and reaching it meant leaving the panel to type the URL by hand. Click the Tailscale mark at the top of the panel, or press `a`, to open it in the default browser, and the panel closes behind it the way it does for a Taildrop send: the browser has taken over. The mark was status-only decoration, so this costs no existing gesture — the toggle switch still owns turning Tailscale on and off from both mouse and keyboard. Which console that is comes from the daemon's own prefs. A tailnet on Tailscale's control plane opens the hosted console; a self-hosted control server has none at that address, so its own URL is the closest thing to one and is what opens instead. The control URL only moves when the connection does, so it is read once and again after an account switch, never on the refresh interval. A daemon that will not answer `debug prefs` leaves the link pointing at the hosted console.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The problem
Machine management — renaming, key expiry, ACLs, approving a subnet route — all lives in the Tailscale admin console, and reaching it from the panel meant leaving it to type the URL by hand.
The change
Click the Tailscale mark at the top of the panel, or press
a, to open the admin console in the default browser viaomarchy-launch-browser. The panel closes behind it the same waysendPeerFilecloses it for a Taildrop send: the browser has taken over.The mark was status-only decoration (
iconComponentin thePanelHero), so this costs no existing gesture. The toggle switch still owns turning Tailscale on and off, from both mouse and keyboard, and the bar icon's left/right/middle click behaviour is untouched.Self-hosted control servers
Which console opens comes from the daemon's own prefs rather than a hardcoded URL.
tailscale status --jsoncarries no control-plane URL, sotailscale debug prefssuppliesControlURL:controlplane/login.tailscale.com→ the hosted console athttps://login.tailscale.com/admin/machinesThe control URL only moves when the connection does, so it is read once at startup and again on the forced refresh that follows an account switch — never on the refresh interval, which would spawn a process every tick for a value that stands still for the life of a login. The poll watchdog stops it like the other three polls. A daemon too old for
debug prefs, or one that refuses it, exits nonzero and leaves the link pointing at the hosted console.Tests
The URL derivation lives in
Model.jsas two pure functions and is covered intest/shell.d/tailscale-test.sh— hosted control plane, empty prefs, trailing slashes, a self-hosted URL, and unparseable prefs. Further assertions cover the wiring: the browser launch, the prefs read, both entry points, and the panel close.Verified live against a hosted tailnet; the self-hosted path is covered by unit tests only, as I have no Headscale server to point at.
🤖 Generated with Claude Code