fix(ssh): isolate managed tunnel processes (#4347)

This commit is contained in:
Yukun Shan authored and GitHub committed 2026-08-04 09:34:23 -04:00
1 parent 82b76e2138
commit 37ae1abbe9
2 files changed
+11

No files matched your search

+5
View File
@@ -381,6 +381,11 @@ describe("ssh tunnel scripts", () => {
const first = yield* manager.ensureEnvironment(target);
assert.equal(first.httpBaseUrl, "http://127.0.0.1:41773/");
const firstTunnelArgs = spawnedCommands.find((args) => args.includes("-N"));
assert.isDefined(firstTunnelArgs);
assert.include(firstTunnelArgs, "ControlMaster=no");
assert.include(firstTunnelArgs, "ControlPath=none");
assert.include(firstTunnelArgs, "ControlPersist=no");
yield* manager.disconnectEnvironment(target);
assert.equal(tunnelKillCount, 1);
+6
View File
@@ -963,6 +963,12 @@ const startSshTunnel = Effect.fn("ssh/tunnel.startSshTunnel")(function* (input:
"-o",
"ExitOnForwardFailure=yes",
"-o",
"ControlMaster=no",
"-o",
"ControlPath=none",
"-o",
"ControlPersist=no",
"-o",
"ServerAliveInterval=15",
"-o",
"ServerAliveCountMax=3",