Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConnectSFTP ¶
func ConnectSFTP(host, username, password, privateKey string, port int, publicKeyAuth, ignoreHostKey bool) (*sftp.Client, error)
connectSFTP creates ssh config, tries to connect (dial) SSH server and creates new client with connection
func Mput ¶
puts a local file or files in the srcFile to remote server *sftp.Client a sftp connection opened by connectSFTP, srcFile resource file or resource directory,dstFile destination file or directory. put will create a subdirectory named with the file name of srcFile in dstFile if srcFile is a directory. return error if error occured,otherwise return nil.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.