Méthode | Description | |
---|---|---|
CopyDirectoryLocally ( string remoteDirectory, string localDirectory ) : void |
Copies a directory to the local filesystem from the remote server
|
|
CopyFileLocally ( string remoteFilePath, string remoteFileName, string localDirectory ) : void |
A method to copy the remote file to the local file
|
|
CreateSession ( ) : void |
Creates a linux ssh session
|
|
Dispose ( ) : void |
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
|
|
ExecuteCommand ( string command ) : string |
Executes a command given a string input in the current context of the user
|
|
ExecuteShell ( List |
Executes a shell command in the context of a sudo su
|
|
ExecuteWithRetries ( string command, int count ) : string |
Executes a command with a prescribed number of retries
|
|
LinuxSession ( string host, int port, string userName, string userPassword, bool disablePasswordLogin, Stream privateKey = null ) : System |
Used to construct a linux session command
|
|
LinuxSession ( string host, int port, string userName, string userPassword, bool disablePasswordLogin, string privateKey = null ) : System |
Used to construct a linux session command
|
|
UploadFile ( string remotePath, string localPath ) : void |
uploads a file to the a directory of the server
|
public CopyDirectoryLocally ( string remoteDirectory, string localDirectory ) : void | ||
remoteDirectory | string | The absolute path of the directory name |
localDirectory | string | The absolute path of the directory name |
Résultat | void |
public CopyFileLocally ( string remoteFilePath, string remoteFileName, string localDirectory ) : void | ||
remoteFilePath | string | The remote file on the server |
remoteFileName | string | The name of the remote file |
localDirectory | string | The local directoryto place the file |
Résultat | void |
public ExecuteCommand ( string command ) : string | ||
command | string | |
Résultat | string |
public ExecuteShell ( List |
||
commands | List |
|
Résultat | Task |
public ExecuteWithRetries ( string command, int count ) : string | ||
command | string | |
count | int | |
Résultat | string |
public LinuxSession ( string host, int port, string userName, string userPassword, bool disablePasswordLogin, Stream privateKey = null ) : System | ||
host | string | |
port | int | |
userName | string | |
userPassword | string | |
disablePasswordLogin | bool | |
privateKey | Stream | |
Résultat | System |
public LinuxSession ( string host, int port, string userName, string userPassword, bool disablePasswordLogin, string privateKey = null ) : System | ||
host | string | |
port | int | |
userName | string | |
userPassword | string | |
disablePasswordLogin | bool | |
privateKey | string | |
Résultat | System |
public UploadFile ( string remotePath, string localPath ) : void | ||
remotePath | string | The absolute remote path of the file - it will be overwritten every time |
localPath | string | the local path from which the file be uploaded |
Résultat | void |