discover

package
v0.5.7 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2022 License: Apache-2.0 Imports: 25 Imported by: 7

Documentation

Index

Constants

View Source
const (
	ProbeHpIlo         = "hpilo"
	ProbeIdrac8        = "idrac8"
	ProbeIdrac9        = "idrac9"
	ProbeSupermicrox   = "supermicrox"
	ProbeSupermicrox11 = "supermicrox11"
	ProbeHpC7000       = "hpc7000"
	ProbeM1000e        = "m1000e"
	ProbeQuanta        = "quanta"
	ProbeHpCl100       = "hpcl100"
)

Variables

This section is empty.

Functions

func ScanAndConnect

func ScanAndConnect(host string, username string, password string, options ...Option) (bmcConnection interface{}, err error)

ScanAndConnect will scan the BMC trying to deduce the device type and return a working connection.

Types

type Option added in v0.3.8

type Option func(*Options)

Option is part of the functional options pattern, see the `With*` functions and https://dave.cheney.net/2014/10/17/functional-options-for-friendly-apis

func WithContext added in v0.4.0

func WithContext(ctx context.Context) Option

WithContext sets the Options.Context option

func WithHintCallBack added in v0.3.8

func WithHintCallBack(fn func(string) error) Option

WithHintCallBack sets the Options.HintCallback option.

func WithLogger added in v0.4.0

func WithLogger(log logr.Logger) Option

WithLogger sets the Options.Logger option

func WithProbeHint added in v0.3.8

func WithProbeHint(hint string) Option

WithProbeHint sets the Options.Hint option.

func WithSecureTLS added in v0.5.3

func WithSecureTLS(rootCAs *x509.CertPool) Option

WithSecureTLS enforces trusted TLS connections, with an optional CA certificate pool. Using this option with an nil pool uses the system CAs.

type Options added in v0.3.8

type Options struct {
	// Hint is a probe ID that hints which probe should be probed first.
	Hint string

	// HintCallBack is a function that is called back with a probe ID that might be used
	// for the next ScanAndConnect attempt.  The callback is called only on successful scan.
	// If your code persists the hint as "best effort", always return a nil error.  Callback is
	// synchronous.
	HintCallback func(string) error
	Logger       logr.Logger
	Context      context.Context
	// contains filtered or unexported fields
}

Options to pass in

type Probe added in v0.3.6

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

Jump to

Keyboard shortcuts

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