Skip to content

fix(android): expose the detached SSH bridge transport as a per-server option - #336

Open
0xr3ngar wants to merge 1 commit into
0xSero:mainfrom
0xr3ngar:fix/ssh-bridge-detached-transport
Open

fix(android): expose the detached SSH bridge transport as a per-server option#336
0xr3ngar wants to merge 1 commit into
0xSero:mainfrom
0xr3ngar:fix/ssh-bridge-detached-transport

Conversation

@0xr3ngar

@0xr3ngar 0xr3ngar commented Aug 28, 2026

Copy link
Copy Markdown

Closes #335.

SSH bridge sessions were spawned with SshBridgeTransport.EPHEMERAL (hardcoded in DiscoveryScreen.kt), so agent processes died with the app. The detached transport already exists in the Rust core (SshDetachedLauncher + detached_spawn.sh), so this just adds a per-server "Detached sessions" toggle (default off, behavior unchanged) and passes DETACHED through when enabled. Unit tests included.

…r option

The Rust core already implements the detached transport (SshDetachedLauncher,
detached_spawn.sh: FIFO stdin + keeper + setsid/nohup, re-attach on
reconnect), but DiscoveryScreen.kt hardcoded SshBridgeTransport.EPHEMERAL so
it was unreachable.

- SavedServer gains a detachedTransport field (persisted, defaults false)
- Add Server SSH flow gains a detached-sessions toggle
- sshConnectBridgeSession receives DETACHED when the toggle is on
- Unit tests: default, JSON round-trip, legacy-missing-field
@0xr3ngar
0xr3ngar marked this pull request as ready for review August 28, 2026 02:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug(android): SSH bridge agent sessions die when the app closes

1 participant