Closed steverice closed 4 years ago
Should we consider just passing everything in options
, just overriding agent
with authAgent
? That way, users all the way up to dockerode
could take advantage of all of ssh2
's options. Would need to check if there are other conflicts though.
@apocas what do you think?
I totally agree, we need to do something about these options.
Instead of passing everything that comes inside the options object since it could potentially lead to problems inside ssh2. We could just use something like "options.sshOptions", then everything that comes inside sshOptions is automatically sent to ssh in https://github.com/apocas/docker-modem/blob/master/lib/modem.js#L210. (everything inside sshOptions would be merged with {host': self.host, 'port': self.port, 'username': self.username, 'password': self.password})
This way we avoid sending a lot of stuff to ssh2 lib and there's an object exactly for that.
@bwateratmsft @apocas thoughts on #119?
Published in v2.1.3
Like #117, add a common SSH option supported by ssh2. All we need to do is pass it in the constructor.