Documentation
¶
Index ¶
- type Ctx
- func (cfg *Ctx) CheckHash(newHash [32]byte) bool
- func (cfg *Ctx) GetAdaptersForSwitch() []string
- func (cfg *Ctx) GetApplicationInstances() []string
- func (cfg *Ctx) GetBaseOSActivate() bool
- func (cfg *Ctx) GetBaseOSConfigs() []string
- func (cfg *Ctx) GetBaseOSContentTree() string
- func (cfg *Ctx) GetBaseOSRetryCounter() uint32
- func (cfg *Ctx) GetBaseOSVersion() string
- func (cfg *Ctx) GetBondAdapters() []string
- func (cfg *Ctx) GetCipherContexts() []*evecommon.CipherContext
- func (cfg *Ctx) GetConfigItems() map[string]string
- func (cfg *Ctx) GetConfigVersion() int
- func (cfg *Ctx) GetContentTrees() []string
- func (cfg *Ctx) GetDevModel() string
- func (cfg *Ctx) GetDiskLayout() *DisksLayout
- func (cfg *Ctx) GetEpoch() int64
- func (cfg *Ctx) GetGlobalProfile() string
- func (cfg *Ctx) GetID() uuid.UUID
- func (cfg *Ctx) GetLocalProfileServer() string
- func (cfg *Ctx) GetNetworkInstances() []string
- func (cfg *Ctx) GetNetworks() []string
- func (cfg *Ctx) GetOnboardKey() string
- func (cfg *Ctx) GetPhysicalIOs() []string
- func (cfg *Ctx) GetProfileServerToken() string
- func (cfg *Ctx) GetRebootCounter() (counter uint32, state bool)
- func (cfg *Ctx) GetRemote() bool
- func (cfg *Ctx) GetRemoteAddr() string
- func (cfg *Ctx) GetSerial() string
- func (cfg *Ctx) GetShutdownCounter() (counter uint32, state bool)
- func (cfg *Ctx) GetState() EdgeNodeState
- func (cfg *Ctx) GetSystemAdapters() []string
- func (cfg *Ctx) GetVlanAdapters() []string
- func (cfg *Ctx) GetVolumes() []string
- func (cfg *Ctx) Reboot()
- func (cfg *Ctx) SetAdaptersForSwitch(adaptersForSwitch []string)
- func (cfg *Ctx) SetApplicationInstanceConfig(configIDs []string) *Ctx
- func (cfg *Ctx) SetBaseOSActivate(baseOSActivate bool) *Ctx
- func (cfg *Ctx) SetBaseOSConfig(configIDs []string) *Ctx
- func (cfg *Ctx) SetBaseOSContentTree(contentTreeID string) *Ctx
- func (cfg *Ctx) SetBaseOSRetryCounter(baseOSRetryCounter uint32) *Ctx
- func (cfg *Ctx) SetBaseOSVersion(baseOSVersion string) *Ctx
- func (cfg *Ctx) SetBondAdaptersConfig(configIDs []string) *Ctx
- func (cfg *Ctx) SetCipherContexts(contexts []*evecommon.CipherContext) *Ctx
- func (cfg *Ctx) SetConfigItem(key, val string)
- func (cfg *Ctx) SetConfigVersion(version int)
- func (cfg *Ctx) SetContentTreeConfig(configIDs []string) *Ctx
- func (cfg *Ctx) SetDevModel(devModel string)
- func (cfg *Ctx) SetDeviceItem(key string, val string) error
- func (cfg *Ctx) SetDiskLayout(diskLayout *DisksLayout) *Ctx
- func (cfg *Ctx) SetEpoch(epoch int64)
- func (cfg *Ctx) SetGlobalProfile(globalProfile string)
- func (cfg *Ctx) SetID(id uuid.UUID)
- func (cfg *Ctx) SetLocalProfileServer(localProfileServer string)
- func (cfg *Ctx) SetNetworkConfig(configIDs []string) *Ctx
- func (cfg *Ctx) SetNetworkInstanceConfig(configIDs []string) *Ctx
- func (cfg *Ctx) SetOnboardKey(key string)
- func (cfg *Ctx) SetPhysicalIOConfig(configIDs []string) *Ctx
- func (cfg *Ctx) SetProfileServerToken(profileServerToken string)
- func (cfg *Ctx) SetProject(name string)
- func (cfg *Ctx) SetRebootCounter(counter uint32, state bool)
- func (cfg *Ctx) SetRemote(remote bool)
- func (cfg *Ctx) SetRemoteAddr(remoteAddr string)
- func (cfg *Ctx) SetSerial(serial string)
- func (cfg *Ctx) SetShutdownCounter(counter uint32, state bool)
- func (cfg *Ctx) SetState(state EdgeNodeState)
- func (cfg *Ctx) SetSystemAdaptersConfig(configIDs []string) *Ctx
- func (cfg *Ctx) SetVlanAdaptersConfig(configIDs []string) *Ctx
- func (cfg *Ctx) SetVolumeConfigs(configIDs []string) *Ctx
- func (cfg *Ctx) Shutdown()
- type DiskType
- type DisksLayout
- type DisksLayoutType
- type EdgeNodeState
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Ctx ¶
type Ctx struct {
// contains filtered or unexported fields
}
Ctx is base struct for EdgeNode
func (*Ctx) GetAdaptersForSwitch ¶
GetAdaptersForSwitch return adaptersForSwitch of device
func (*Ctx) GetApplicationInstances ¶
GetApplicationInstances return applicationInstanceConfigs of device
func (*Ctx) GetBaseOSActivate ¶ added in v1.0.0
GetBaseOSActivate return baseOSActivate of device
func (*Ctx) GetBaseOSConfigs ¶
GetBaseOSConfigs return baseOSConfigs of device
func (*Ctx) GetBaseOSContentTree ¶ added in v1.0.0
GetBaseOSContentTree return baseOSContentTree of device
func (*Ctx) GetBaseOSRetryCounter ¶ added in v1.0.0
GetBaseOSRetryCounter return baseOSRetryCounter of device
func (*Ctx) GetBaseOSVersion ¶ added in v1.0.0
GetBaseOSVersion returns baseOSVersion
func (*Ctx) GetBondAdapters ¶ added in v1.0.0
GetBondAdapters return bondAdapters of device
func (*Ctx) GetCipherContexts ¶
func (cfg *Ctx) GetCipherContexts() []*evecommon.CipherContext
GetCipherContexts get CipherContexts of device
func (*Ctx) GetConfigItems ¶
GetConfigItems return GetConfigItems of device
func (*Ctx) GetConfigVersion ¶
GetConfigVersion return configVersion of device
func (*Ctx) GetContentTrees ¶
GetContentTrees return ContentTrees of device
func (*Ctx) GetDevModel ¶
GetDevModel return devModel of device
func (*Ctx) GetDiskLayout ¶ added in v1.0.0
func (cfg *Ctx) GetDiskLayout() *DisksLayout
GetDiskLayout get DiskLayout of device
func (*Ctx) GetGlobalProfile ¶
GetGlobalProfile get globalProfile
func (*Ctx) GetLocalProfileServer ¶
GetLocalProfileServer get localProfileServer
func (*Ctx) GetNetworkInstances ¶
GetNetworkInstances return networkInstances of device
func (*Ctx) GetNetworks ¶
GetNetworks return networks of device
func (*Ctx) GetPhysicalIOs ¶
GetPhysicalIOs return physicalIO of device
func (*Ctx) GetProfileServerToken ¶
GetProfileServerToken get profileServerToken
func (*Ctx) GetRebootCounter ¶
GetRebootCounter getter
func (*Ctx) GetRemoteAddr ¶
GetRemoteAddr return remote address to access EVE
func (*Ctx) GetShutdownCounter ¶ added in v1.0.0
GetShutdownCounter getter
func (*Ctx) GetSystemAdapters ¶
GetSystemAdapters return systemAdapters of device
func (*Ctx) GetVlanAdapters ¶ added in v1.0.0
GetVlanAdapters return vlansAdapters of device
func (*Ctx) SetAdaptersForSwitch ¶
SetAdaptersForSwitch set adaptersForSwitch of device
func (*Ctx) SetApplicationInstanceConfig ¶
SetApplicationInstanceConfig set applicationInstanceConfigs by configIDs from cloud
func (*Ctx) SetBaseOSActivate ¶ added in v1.0.0
SetBaseOSActivate set baseOSActivate
func (*Ctx) SetBaseOSConfig ¶
SetBaseOSConfig set BaseOSConfig by configIDs from cloud
func (*Ctx) SetBaseOSContentTree ¶ added in v1.0.0
SetBaseOSContentTree set baseOSContentTree by contentTreeID from cloud
func (*Ctx) SetBaseOSRetryCounter ¶ added in v1.0.0
SetBaseOSRetryCounter set baseOSRetryCounter
func (*Ctx) SetBaseOSVersion ¶ added in v1.0.0
SetBaseOSVersion set baseOSVersion
func (*Ctx) SetBondAdaptersConfig ¶ added in v1.0.0
SetBondAdaptersConfig set bondAdapters by configIDs from cloud
func (*Ctx) SetCipherContexts ¶
func (cfg *Ctx) SetCipherContexts(contexts []*evecommon.CipherContext) *Ctx
SetCipherContexts set CipherContexts for device
func (*Ctx) SetConfigItem ¶
SetConfigItem set ConfigItem of device
func (*Ctx) SetConfigVersion ¶
SetConfigVersion set configVersion of device
func (*Ctx) SetContentTreeConfig ¶
SetContentTreeConfig set contentTrees configs by configIDs from cloud
func (*Ctx) SetDeviceItem ¶
SetDeviceItem for setting devConfig fields
func (*Ctx) SetDiskLayout ¶ added in v1.0.0
func (cfg *Ctx) SetDiskLayout(diskLayout *DisksLayout) *Ctx
SetDiskLayout set DiskLayout for device
func (*Ctx) SetGlobalProfile ¶
SetGlobalProfile set globalProfile
func (*Ctx) SetLocalProfileServer ¶
SetLocalProfileServer set localProfileServer
func (*Ctx) SetNetworkConfig ¶
SetNetworkConfig set networks by configIDs from cloud
func (*Ctx) SetNetworkInstanceConfig ¶
SetNetworkInstanceConfig set NetworkInstanceConfig by configIDs from cloud
func (*Ctx) SetPhysicalIOConfig ¶
SetPhysicalIOConfig set physicalIO by configIDs from cloud
func (*Ctx) SetProfileServerToken ¶
SetProfileServerToken set profileServerToken
func (*Ctx) SetRebootCounter ¶
SetRebootCounter setter
func (*Ctx) SetRemoteAddr ¶
SetRemoteAddr set remote address to access EVE
func (*Ctx) SetShutdownCounter ¶ added in v1.0.0
SetShutdownCounter setter
func (*Ctx) SetSystemAdaptersConfig ¶
SetSystemAdaptersConfig set systemAdapters by configIDs from cloud
func (*Ctx) SetVlanAdaptersConfig ¶ added in v1.0.0
SetVlanAdaptersConfig set vlanAdapters by configIDs from cloud
func (*Ctx) SetVolumeConfigs ¶
SetVolumeConfigs set volumes configs by configIDs from cloud
type DisksLayout ¶ added in v1.0.0
type DisksLayout struct {
DiskType DiskType // to calculate name based on index
LayoutType DisksLayoutType
OfflineDisks []uint // indexes of offline disks
UnusedDisks []uint // indexes of unused disks
ReplaceDisks []uint // indexes of disks to be replaced. Replacements will be selected from disks not in use
PartDisks []uint // indexes of disks to use partition in name
}
DisksLayout stores data for disks layout preparation
func ParseDiskLayout ¶ added in v1.0.0
func ParseDiskLayout(disksConfig *config.DisksConfig) (*DisksLayout, error)
ParseDiskLayout from configuration
func (*DisksLayout) GetDisksConfig ¶ added in v1.0.0
func (layout *DisksLayout) GetDisksConfig() (*config.DisksConfig, error)
GetDisksConfig returns disks config based on layout
func (*DisksLayout) String ¶ added in v1.0.0
func (layout *DisksLayout) String() string
String returns string representation of disks layout
type DisksLayoutType ¶ added in v1.0.0
type DisksLayoutType int
DisksLayoutType stores expectation about disks layout
const ( DisksLayoutTypeUnspecified DisksLayoutType = iota // no configured DisksLayoutTypeRaid1 // mirror (2 disks) DisksLayoutTypeRaid10 // striped mirrors (4 disks) )
DisksLayoutType enum
type EdgeNodeState ¶
type EdgeNodeState int
EdgeNodeState determinate state of EdgeNode
var ( //NotOnboarded EdgeNode NotOnboarded EdgeNodeState //Onboarded EdgeNode Onboarded EdgeNodeState = 1 )