ssh2: some options were not optional in ConnectConfig (#9310)

This commit is contained in:
Pēteris Ņikiforovs
2016-05-14 20:04:59 +03:00
committed by Masahiro Wakame
parent e653cba45e
commit aa3428bea8
2 changed files with 11 additions and 2 deletions

View File

@@ -293,6 +293,15 @@ conn.on('ready', () => {
password: 'honk'
});
// ConnectConfig
const sshconfig: ssh2.ConnectConfig = {
host: 'localhost',
port: 22,
username: 'ubuntu',
password: 'password'
};
//
// # Server Examples
//

4
ssh2/ssh2.d.ts vendored
View File

@@ -109,7 +109,7 @@ declare module "ssh2" {
* @description Try keyboard-interactive user authentication if primary user authentication method fails.
* If you set this to `true`, you need to handle the `keyboard-interactive` event.
*/
tryKeyboard: boolean;
tryKeyboard?: boolean;
/**
* @description How often (in milliseconds) to send SSH-level keepalive packets to the server
* (in a similar way as OpenSSH's ServerAliveInterval config option). Set to 0 to disable.
@@ -145,7 +145,7 @@ declare module "ssh2" {
/**
* @description Set this to a function that receives a single string argument to get detailed (local) debug information.
*/
debug: (information: string) => any;
debug?: (information: string) => any;
}
interface ExecOption {