Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cfg ¶
type Cfg struct {
Username string `json:"username"`
Password string `json:"password"`
Address string `json:"address"`
Port int `json:"port"`
PrivateKey string `json:"-"`
KeyFile string `json:"-"`
AgentSocket string `json:"-"`
Timeout time.Duration `json:"timeout"`
Bastion string `json:"-"`
BastionPort int `json:"-"`
BastionUser string `json:"-"`
}
type Connection ¶
type Connection interface {
SftpCli() *sftp.Client
Exec(cmd string) (stdout string, err error)
Close()
}
func NewConnection ¶
func NewConnection(cfg Cfg) (Connection, error)
Click to show internal directories.
Click to hide internal directories.