sshtl

package
v1.0.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 24, 2020 License: MIT Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	M_bDebug = true
)

Functions

This section is empty.

Types

type SSHTool

type SSHTool struct {
	Client *ssh.Client
}

func (*SSHTool) SSHConnect

func (o *SSHTool) SSHConnect(user, password, host string, port int) error

ssh 连接

参数
	user 账号
	password 密码
	host 主机
	port 端口

func (*SSHTool) SSHRunCmd

func (o *SSHTool) SSHRunCmd(cmd string) (string, error)

运行命令

func (*SSHTool) SetDebugMode

func (o *SSHTool) SetDebugMode(bDebug bool)

设置调试模式

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL