Add custom coordination server support#83
Open
dantraynor wants to merge 4 commits into
Open
Conversation
# Conflicts: # docs/DOCUMENTATION.md # packages/extension/package.json # packages/shared/package.json # packages/shared/src/background/background.test.ts # packages/shared/src/constants.ts # packages/shared/src/popup/views/connected.ts # scripts/e2e/fixtures.mjs # scripts/e2e/native-host.mjs # scripts/e2e/scenarios/connected-dashboard.mjs
Follow-up fixes to the custom coordination server feature. Native host: - Reword the failed-switch rollback message to reflect that logout already signed the node out and a new login is required. - Clear the old tailnet's exit-node prefs when switching servers so a now-invalid ExitNodeID isn't carried onto the new server. - Reset cached prefs on the double-failure rollback paths. - Keep IPv6 brackets in control-URL compare keys (net.JoinHostPort). - Validate the control URL at the host boundary. Extension: - Accept http:// coordination URLs (HTTP Headscale), matching the host. - Preserve unsaved input across status updates via a dirty flag. - Patch the Admin Console footer link in place instead of re-rendering. - Keep waiting for a fresh login URL instead of opening a stale one. - Allow reverting to the default server when the helper lacks support. - Validate the control URL at the background boundary. - Single-source the default-origin list shared across modules. - Clear the cached login URL and saved exit node on a server switch so an immediate re-login or post-restart restore can't reuse old data. - Consolidate the coordination editor wiring across the connected, needs-login, and disconnected views into one focus-preserving helper. Add Go and TypeScript tests for the new behavior.
Three correctness fixes for switching to a custom coordination server: - controlServerChanged now mirrors the host's compare key (scheme+host lowercased, path/query preserved) so a same-origin path-only switch is detected as a real change instead of looking unchanged. - Drop the saved exit node reactively, only once a status update confirms the host committed the new server, so a rolled-back switch no longer loses it. The optimistic browseToURL clear stays. - Narrow the pending-login "stay pending" branch to stale default-origin URLs only; a genuinely-invalid custom login URL now surfaces an error toast instead of spinning silently until the timeout.
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.
What
Adds custom coordination server URL support across the native host, background state, and popup UI, and bumps the extension/helper version to 0.2.0.
Why
Closes #79
How to Test
go test ./...pnpm typecheckpnpm testpnpm e2e:chrome -- --suite=full --grep="needs update on host version mismatch"Checklist