healthchecks

package
v1.7.0 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Perform

func Perform(sshContext *ssh.SSHContext, host Host, timeout int) (err error)

Types

type CmdHealthCheck

type CmdHealthCheck struct {
	SshContext  *ssh.SSHContext
	Description string
	Cmd         []string
	Period      int
	Timeout     int
}

func (CmdHealthCheck) GetDescription

func (healthCheck CmdHealthCheck) GetDescription() string

func (CmdHealthCheck) GetPeriod

func (healthCheck CmdHealthCheck) GetPeriod() int

func (CmdHealthCheck) Run

func (healthCheck CmdHealthCheck) Run(host Host) error

type HealthCheck

type HealthCheck interface {
	GetDescription() string
	GetPeriod() int
	Run(Host) error
}

type HealthChecks

type HealthChecks struct {
	Http []HttpHealthCheck
	Cmd  []CmdHealthCheck
}

type Host

type Host interface {
	GetName() string
	GetTargetHost() string
	GetTargetPort() int
	GetTargetUser() string
	GetHealthChecks() HealthChecks
}

type HttpHealthCheck

type HttpHealthCheck struct {
	Description string
	Headers     map[string]string
	Host        *string
	InsecureSSL bool
	Path        string
	Port        int
	Scheme      string
	Period      int
	Timeout     int
}

func (HttpHealthCheck) GetDescription

func (healthCheck HttpHealthCheck) GetDescription() string

func (HttpHealthCheck) GetPeriod

func (healthCheck HttpHealthCheck) GetPeriod() int

func (HttpHealthCheck) Run

func (healthCheck HttpHealthCheck) Run(host Host) error

Jump to

Keyboard shortcuts

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