I recently discovered that knife-cloud was incorrectly handling options for specifying the remote SSH port of the node you want to bootstrap when using an SSH gateway. The problem was that it was only honoring the deprecated --ssh-port option and not the replacement option --connection-port. It also lacked a default of port 22, so when --ssh-port was unspecified, nil was being passed as the remote port for the SSH gateway. From my cursory reading of RFC 4254 not passing a remote port is unspecified behavior so I've added a default for the remote port.
Can you please clarify the difference between the pre-merge tests and all new and existing tests? I have passing tests per rake spec && rake style.
I didn't see any relevant documentation to update, but if I've missed something please let me know and I'll address it.
Description
I recently discovered that knife-cloud was incorrectly handling options for specifying the remote SSH port of the node you want to bootstrap when using an SSH gateway. The problem was that it was only honoring the deprecated
--ssh-port
option and not the replacement option--connection-port
. It also lacked a default of port 22, so when--ssh-port
was unspecified,nil
was being passed as the remote port for the SSH gateway. From my cursory reading of RFC 4254 not passing a remote port is unspecified behavior so I've added a default for the remote port.Related Issue
https://github.com/chef/knife-cloud/issues/134
Types of changes
Checklist:
Can you please clarify the difference between the pre-merge tests and all new and existing tests? I have passing tests per
rake spec && rake style
. I didn't see any relevant documentation to update, but if I've missed something please let me know and I'll address it.