ssh

package
v0.20.4-rc2 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2021 License: Apache-2.0 Imports: 18 Imported by: 2

Documentation

Index

Constants

View Source
const (
	// DriverName is the name of the ssh driver
	DriverName = "ssh"
	// DefaultUsername is the default username used for ssh operations
	DefaultUsername = "root"
	// DefaultSSHPort is the default port used for ssh operations
	DefaultSSHPort = 22
	// DefaultSSHKey is the default public keyPath path used for ssh operations
	DefaultSSHKey = "/home/torpedo/key4torpedo.pem"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type SSH

type SSH struct {
	node.Driver
	// contains filtered or unexported fields
}

SSH ssh node driver

func (*SSH) FindFiles

func (s *SSH) FindFiles(path string, n node.Node, options node.FindOpts) (string, error)

FindFiles finds files from give path on given node

func (*SSH) Init

func (s *SSH) Init() error

Init initializes SSH node driver

func (*SSH) RebootNode

func (s *SSH) RebootNode(n node.Node, options node.RebootNodeOpts) error

RebootNode reboots given node

func (*SSH) RecoverDrive

func (s *SSH) RecoverDrive(n node.Node, driveNameToRecover string, driveUUIDToRecover string, options node.ConnectionOpts) error

RecoverDrive recovers given drive on given node

func (*SSH) RunCommand

func (s *SSH) RunCommand(n node.Node, command string, options node.ConnectionOpts) (string, error)

RunCommand runs given command on given node

func (*SSH) ShutdownNode

func (s *SSH) ShutdownNode(n node.Node, options node.ShutdownNodeOpts) error

ShutdownNode shuts down given node

func (*SSH) String

func (s *SSH) String() string

func (*SSH) SystemCheck

func (s *SSH) SystemCheck(n node.Node, options node.ConnectionOpts) (string, error)

SystemCheck check if any cores are generated on given node

func (*SSH) Systemctl

func (s *SSH) Systemctl(n node.Node, service string, options node.SystemctlOpts) error

Systemctl allows to run systemctl commands on a give node

func (*SSH) TestConnection

func (s *SSH) TestConnection(n node.Node, options node.ConnectionOpts) error

TestConnection tests the connection to the given node

func (*SSH) YankDrive

func (s *SSH) YankDrive(n node.Node, driveNameToFail string, options node.ConnectionOpts) (string, error)

YankDrive yanks given drive on given node

Jump to

Keyboard shortcuts

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