Fix SSH agent and identity file auth ordering (#2681)

* fix: address review findings

* fix: address CI failures
This commit is contained in:
Jinjing
2026-05-23 01:56:15 -07:00
committed by GitHub
parent d7d7f3b8f6
commit ffec74c7ba
12 changed files with 1020 additions and 78 deletions
+8
View File
@@ -177,6 +177,14 @@ export function buildSshArgs(target: SshTarget): string[] {
args.push('-i', target.identityFile)
}
if (!useConfigHost && target.identityAgent) {
args.push('-o', `IdentityAgent=${target.identityAgent}`)
}
if (!useConfigHost && target.identitiesOnly) {
args.push('-o', 'IdentitiesOnly=yes')
}
if (!useConfigHost && target.jumpHost) {
args.push('-J', target.jumpHost)
}