fix: ignore the SSH config file setting where ssh never reads it - #1063
Closed
EhabY wants to merge 1 commit into
Closed
fix: ignore the SSH config file setting where ssh never reads it#1063EhabY wants to merge 1 commit into
EhabY wants to merge 1 commit into
Conversation
Antigravity and Windsurf/Devin renamed the setting to remote.antigravitySSH.configFile and remote.devinSSH.configFile, then spawn ssh without -F, so ssh reads ~/.ssh/config no matter what any of them say. The setting only feeds their own host tree. Honoring it, or a stale remote.SSH.configFile synced in from another editor, writes the workspace host to a file the connection never reads. Ignore it on those two and keep reading remote.SSH.configFile elsewhere: Microsoft's extension and Cursor's fork pass it to ssh with -F, and VSCodium's fork parses the file itself instead of running ssh. This drops the per-extension section map from #1060: the three extensions that do connect through the setting all read remote.SSH.
Collaborator
Author
|
Folded into #1061. |
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.
Follow-up to #1060, which shipped an incorrect premise.
Problem
#1060 assumed every Remote-SSH extension connects through the config file its
configFilesetting names. Two of them do not.Antigravity and Windsurf/Devin spawn ssh as
-v -T [-o RemoteCommand=none] -D <port> <dest> bash -s— no-Fanywhere in either bundle (the only-Ftoken is agrep -Fin their remote install script). TheirgetSSHConfigPath()feeds the host tree, the file watcher and the "Open SSH Configuration File" command, and nothing else. ssh therefore reads its own default~/.ssh/configno matter whatremote.antigravitySSH.configFileorremote.devinSSH.configFilesays.So after #1060, a user who set one of those got the workspace host written to a file the connection never reads, and the connection failed. Before #1060 that user had a cosmetic mismatch only. The same applies to a stale
remote.SSH.configFilesynced in from VS Code, which those editors also never pass to ssh.Change
Ignore the setting on those two extensions and read
remote.SSH.configFileeverywhere else, because the three extensions that genuinely connect through it all use that name:ms-vscode-remote.remote-ssh-Fanysphere.remote-ssh-Fjeanp413.open-remote-sshssh2, never runs ssh)google.antigravity-remote-opensshcodeium.windsurf-remote-opensshThat makes #1060's per-extension section map inert, so it is removed: the renamed sections belong exclusively to extensions we now skip. The rule is documented in
CONTRIBUTING.mdnext to the SSH config flow.Known cosmetic trade-off: on those two editors, a user pointing the setting elsewhere will not see Coder workspaces in the extension's host tree. Their own hosts in that file are equally unreachable for the same upstream reason, so this restores the pre-#1060 behaviour rather than introducing a new gap.
Testing
getRemoteSshConfigFileis covered for the three honouring extensions, for both ignoring ones (including with a staleremote.SSH.configFilepresent), for no extension installed, and for nothing configured. Full suite passes, plus lint and typecheck.🤖 Generated with Claude Code