ssh

package
v0.1.0-alpha.0 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2019 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SSHClient

type SSHClient struct {
	// contains filtered or unexported fields
}

SSHClient represents a client used to connect to an SSH server

func New

func New(user string, privateKeyPath string) *SSHClient

New creates uses the user and privateKeyPath to create an *SSHClient

func (*SSHClient) Dial

func (c *SSHClient) Dial(addr string) error

Dial connects a remote SSH host at address addr

func (*SSHClient) Hangup

func (c *SSHClient) Hangup() error

Hangup closes the established SSH connection

func (*SSHClient) SSHRun

func (c *SSHClient) SSHRun(cmd string, args ...string) (io.Reader, error)

SSHRun executes the specified command on a remote host over SSH

Jump to

Keyboard shortcuts

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