machine

package
v0.0.0-...-7a62f64 Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AgentKey

type AgentKey string

func AgentKeyFromString

func AgentKeyFromString(v string) (AgentKey, error)

func (AgentKey) String

func (m AgentKey) String() string

type Identifier

type Identifier string

func IdentifierFromString

func IdentifierFromString(identifier string) (Identifier, error)

func (Identifier) String

func (m Identifier) String() string

type Machine

type Machine struct {
	Identifier        Identifier
	AgentEndpoint     MachineEndpoint
	AgentApiKey       AgentKey
	PowerCapabilities PowerCapabilities
	Class             machine.MachineClass
	Tags              []*tag.Tag
	LastHeartbeat     time.Time
	RegisteredAt      time.Time
	UpdatedAt         time.Time
	Status            *power.Status
	Host              *host.Host
	Cpu               *cpu.CPU
	Memory            *memory.Memory
	Disks             []*storage.Disk
	NetworkInterfaces []*network.Nic
	Volumes           []*storage.Volume
	Addresses         []*network.IpAddress
}

func NewMachine

func NewMachine(identifier Identifier, endpoint MachineEndpoint, key AgentKey, class machine.MachineClass, lastHeartbeat time.Time, registeredAt time.Time, updatedAt time.Time, status *power.Status, cap PowerCapabilities, host *host.Host, cpu *cpu.CPU, memory *memory.Memory, disks []*storage.Disk, networkInterfaces []*network.Nic, volumes []*storage.Volume, addresses []*network.IpAddress) *Machine

type MachineEndpoint

type MachineEndpoint string

func MachineEndpointFromString

func MachineEndpointFromString(v string) (MachineEndpoint, error)

func (MachineEndpoint) String

func (m MachineEndpoint) String() string

type PowerCapabilities

type PowerCapabilities struct {
	WakeOnLan PowerCapabilityWakeOnLan
	PowerOff  PowerCapabilityPowerOff
	Reboot    PowerCapabilityReboot
}

type PowerCapabilityPowerOff

type PowerCapabilityPowerOff struct {
	Enabled bool
}

func NewPowerCapabilityPowerOff

func NewPowerCapabilityPowerOff(enabled bool) *PowerCapabilityPowerOff

type PowerCapabilityReboot

type PowerCapabilityReboot struct {
	Enabled bool
}

func NewPowerCapabilityReboot

func NewPowerCapabilityReboot(enabled bool) *PowerCapabilityReboot

type PowerCapabilityWakeOnLan

type PowerCapabilityWakeOnLan struct {
	Enabled    bool
	MacAddress *network.MacAddress
}

func NewPowerCapabilityWakeOnLan

func NewPowerCapabilityWakeOnLan(enabled bool, macAddress *network.MacAddress) *PowerCapabilityWakeOnLan

Jump to

Keyboard shortcuts

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