Documentation ¶
Index ¶
Constants ¶
View Source
const ( NICStateNotFound = iota NICStateDown NICStateLowerDown NICStateUP )
View Source
const ( ErrMsgVLANShouldBeANumberInRange string = "VLAN ID should be a number 1 ~ 4094." ErrMsgMTUShouldBeANumber string = "MTU should be a number." NtpSettingName string = "ntp-servers" ErrMsgNoDefaultRoute string = "No default route found. Please check the router setting on the DHCP server." )
View Source
const ( ElementalConfigDir = "/tmp/elemental" ElementalConfigFile = "config.yaml" )
View Source
const ( EventInstallStarted = "STARTED" EventInstallSuceeded = "SUCCEEDED" EventInstallFailed = "FAILED" PasswordMask = "******" )
View Source
const (
WebhookMaxRetries = 3
)
Variables ¶
View Source
var ( ErrMsgModeCreateContainsServerURL = fmt.Sprintf("ServerURL need to be empty in %s mode", config.ModeCreate) ErrMsgModeJoinServerURLNotSpecified = fmt.Sprintf("ServerURL can't empty in %s mode", config.ModeJoin) ErrMsgModeUnknown = "unknown mode" ErrMsgTokenNotSpecified = "token not specified" ErrMsgISOURLNotSpecified = "iso_url is required in automatic installation" ErrMsgMgmtInterfaceNotSpecified = "no management interface specified" ErrMsgMgmtInterfaceInvalidMethod = "management network must configure with either static or DHCP method" ErrMsgMgmtInterfaceStaticNoDNS = "DNS servers are required for static IP address" ErrMsgInterfaceNotSpecified = "no interface specified" ErrMsgInterfaceNotSpecifiedForMgmt = "no interface specified for management network" ErrMsgInterfaceNotFound = "interface not found" ErrMsgInterfaceIsLoop = "interface is a loopback interface" ErrMsgDeviceNotSpecified = "no device specified" ErrMsgDeviceNotFound = "device not found" ErrMsgDeviceTooSmall = fmt.Sprintf("device size too small. At least %dG is required", config.SingleDiskMinSizeGiB) ErrMsgNoCredentials = "no SSH authorized keys or passwords are set" ErrMsgForceMBROnLargeDisk = "disk size too large for MBR partitioning table" ErrMsgForceMBROnUEFI = "cannot force MBR on UEFI system" ErrMsgNetworkMethodUnknown = "unknown network method" ErrMsgSystemSettingsUnknown = "unknown system settings: %s" ErrMsgManagementInterfaceNotFound = "" /* 175-byte string literal not displayed */ ErrMsgUnsupportedSchemeVersion = "" /* 139-byte string literal not displayed */ ErrContainerdRegistrySettingNotValidJSON = "could not parse containerd-registry as JSON" )
Functions ¶
func IsValidEvent ¶
func IsValidHTTPMethod ¶
Types ¶
type ConfigValidator ¶
type ConfigValidator struct { }
func (ConfigValidator) Validate ¶
func (v ConfigValidator) Validate(cfg *config.HarvesterConfig) error
type Console ¶
Console is the structure of the harvester console
func (*Console) AddElement ¶
AddElement adds an element with name
func (*Console) CloseElement ¶
func (*Console) CloseElements ¶
func (*Console) GetElement ¶
GetElement gets an element by name
func (*Console) ShowElement ¶ added in v1.0.1
ShowElement shows the element by name
type RenderedWebhook ¶
func (*RenderedWebhook) DebugOutput ¶ added in v1.1.2
func (p *RenderedWebhook) DebugOutput(format string)
func (*RenderedWebhook) Handle ¶
func (p *RenderedWebhook) Handle() error
type RendererWebhooks ¶
type RendererWebhooks []RenderedWebhook
func PrepareWebhooks ¶
func (RendererWebhooks) Handle ¶
func (hooks RendererWebhooks) Handle(event string)
type Spinner ¶
type Spinner struct {
// contains filtered or unexported fields
}
func NewFocusSpinner ¶ added in v0.2.3
type TaskResult ¶
type TaskResult struct {
// contains filtered or unexported fields
}
type UserInputData ¶
type ValidatorInterface ¶
type ValidatorInterface interface {
Validate(cfg *config.HarvesterConfig) error
}
Click to show internal directories.
Click to hide internal directories.