-
Notifications
You must be signed in to change notification settings - Fork 29
Description
So far, Nerdlog implements ssh connections using the golang.org/x/crypto/ssh library. The problem is that this library doesn't support reading ~/.ssh/config
, so Nerdlog also has to use a separate ssh_config library, which is very limited btw. All in all, it means that if we have ssh config with globs like this one:
Host *.server.com
User me
Or using Match
directive, Nerdlog doesn't properly make use of that, and needs to be configured separately.
So this issue is about the following: introduce an option like transport
, with 3 possible values:
ssh-bin-if-available
: this will be the default on all Unix-like systems. As the name suggests, it will check if the externalssh
binary if available, and if so, use that, otherwise use internal library;ssh-bin
: always use external binaryssh-lib
: always use internal library (this should likely be the default on Windows, at least until external ssh is tested there)
Even with the external ssh, Nerdlog will still need to parse the ssh config, at least to know the list of the available hosts to implement its own globbing, but still it will be a significant improvement. Also it will likely mean that we don't have to implement support for the Match
directive at all.