Skip to content

fix: resolve ssh config per connection target - #254

Merged
inureyes merged 1 commit into
mainfrom
fix/issue-249-per-node-ssh-config
Aug 2, 2026
Merged

fix: resolve ssh config per connection target#254
inureyes merged 1 commit into
mainfrom
fix/issue-249-per-node-ssh-config

Conversation

@inureyes

@inureyes inureyes commented Aug 2, 2026

Copy link
Copy Markdown
Member

Summary

Resolve SSH connection settings per target host instead of once per dispatch, covering AddressFamily, Compression, ServerAliveInterval, and ServerAliveCountMax for exec, ping, upload, and download.

What changed

  • Added SshConnectionConfigResolver to combine CLI overrides, YAML defaults, and ssh_config Host blocks, with fixed-config compatibility for existing callers.
  • Resolved connection settings at the ParallelExecutor per-node seam and passed the resolver through SshClient and JumpHostChain so jump hops resolve against their own Host blocks.
  • Updated SFTP transfer paths to carry the full resolved SshConnectionConfig instead of only AddressFamily.
  • Added tests for per-node executor resolution, resolver CLI precedence, and jump-hop Host block resolution.

Test plan

  • cargo fmt
  • cargo test --lib executor::parallel::tests::connection_config_for_node_resolves_each_node_host_block
  • cargo test --lib ssh::tokio_client::connection_tests::test_connection_config_resolver
  • cargo test --lib jump::chain::tests::test_chain_resolves_connection_config_per_jump_host
  • cargo check --lib --tests
  • cargo clippy --lib --tests -- -D warnings

Closes #249

Add a per-host SshConnectionConfigResolver so exec, ping, upload, and download resolve AddressFamily, Compression, ServerAliveInterval, and ServerAliveCountMax against each target node instead of a once-per-dispatch fallback.

Pass the same resolver into jump chains so each jump hop resolves against its own Host block, while preserving fixed-config compatibility for existing callers.

Validated with cargo fmt, cargo test --lib executor::parallel::tests::connection_config_for_node_resolves_each_node_host_block, cargo test --lib ssh::tokio_client::connection_tests::test_connection_config_resolver, cargo test --lib jump::chain::tests::test_chain_resolves_connection_config_per_jump_host, cargo check --lib --tests, and cargo clippy --lib --tests -- -D warnings.

Closes #249
@inureyes inureyes added type:bug Something isn't working priority:low Low priority issue status:review Under review status:done Completed and removed status:review Under review labels Aug 2, 2026
@inureyes
inureyes merged commit 30e0fdd into main Aug 2, 2026
3 checks passed
@inureyes
inureyes deleted the fix/issue-249-per-node-ssh-config branch August 2, 2026 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

priority:low Low priority issue status:done Completed type:bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix: resolve per-host ssh_config connection settings per node instead of once per dispatch

1 participant