services

package
v0.0.0-...-f67af4a Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Machine

type Machine struct {
	Name string

	Networking MachineNetworking

	Options MachineOptions
	Domain  libvirt.Domain

	Status MachineStatus
}

func CreateMachine

func CreateMachine(virt *libvirt.Libvirt, options MachineOptions) *Machine

func (*Machine) AttachAgentSock

func (m *Machine) AttachAgentSock(virt *libvirt.Libvirt)

func (*Machine) DetermineNetworking

func (m *Machine) DetermineNetworking(virt *libvirt.Libvirt) *MachineNetworking

func (*Machine) PostCreate

func (m *Machine) PostCreate(virt *libvirt.Libvirt)

type MachineNetworking

type MachineNetworking struct {
	MacAddr string `json:"mac_addr"`
	IpAddr  string `json:"ip_addr"`
}

TODO: Extend this into support multiple interfaces. The machine might have been set up in such a way that it has passthrough of a physcial card and the virtual card.

type MachineOptions

type MachineOptions struct {
	Name     string
	Memory   int64
	VCpu     int64
	Template string
}

type MachineStatus

type MachineStatus struct {
	HasIP    bool `json:"has_ip"`
	HasAgent bool `json:"has_agent"`
	Running  bool `json:"running"`
}

Jump to

Keyboard shortcuts

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