model

package
v0.1.4 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Common added in v0.1.1

type Common struct {
}

type ConfigVmParamsParameter

type ConfigVmParamsParameter struct {

	// config params name
	Name string `json:"name,omitempty"`
	// config params value
	Value string `json:"value,omitempty"`
}

type CreateVmnetParameter

type CreateVmnetParameter struct {
	Common

	// The host network name
	Name string `json:"name"`
	// The host network type
	Type string `json:"type,omitempty"`
}

type DaemonState

type DaemonState string
const (
	STATE_ON  DaemonState = "on"
	STATE_OFF DaemonState = "off"
)

List of DaemonState

type DhcpConfig

type DhcpConfig struct {
	Common

	Enabled bool   `json:"enabled"`
	Setting string `json:"setting"`
}

DHCP configuration

type DnsConfig

type DnsConfig struct {
	Common

	Hostname   string   `json:"hostname,omitempty"`
	Domainname string   `json:"domainname,omitempty"`
	Server     []string `json:"server,omitempty"`
	Search     []string `json:"search,omitempty"`
}

DNS configuration

type ErrorModel

type ErrorModel struct {
	Common

	Code    int    `json:"code"`
	Message string `json:"message"`
}

type InlineResponse200

type InlineResponse200 struct {
	Common

	// Guest OS IP address
	Ip string `json:"ip"`
}

type MacToIpParameter

type MacToIpParameter struct {
	Common

	IP string `json:"IP"`
}

type MactoIp

type MactoIp struct {
	Common

	Vmnet string `json:"vmnet"`
	Mac   string `json:"mac"`
	Ip    string `json:"ip"`
}

The MAC to IP setting

type MactoIps

type MactoIps struct {
	Common

	Num int `json:"num"`
	// The list of MAC to IP settings
	Mactoips []MactoIp `json:"mactoips,omitempty"`
}

The list of MAC to IP settings

type Network

type Network struct {
	Common

	// Name of virtual network
	Name   string `json:"name"`
	Type   string `json:"type"`
	Dhcp   string `json:"dhcp"`
	Subnet string `json:"subnet"`
	Mask   string `json:"mask"`
}

The virtual network

type Networks

type Networks struct {
	Common

	Num int `json:"num"`
	// The list of virtual networks
	Vmnets []Network `json:"vmnets"`
}

The list of virtual networks

type NicDevice

type NicDevice struct {
	Common

	Index int `json:"index"`
	// The network type of network adapter
	Type string `json:"type"`
	// The vmnet name
	Vmnet string `json:"vmnet"`
	// Mac address
	MacAddress string `json:"macAddress"`
}

type NicDeviceParameter

type NicDeviceParameter struct {
	Common

	// The network type of network adapter
	Type string `json:"type"`
	// The vmnet name, it should only be used while type is custom
	Vmnet string `json:"vmnet"`
}

type NicDevices

type NicDevices struct {
	Common

	Num int `json:"num"`
	// The network adapter added to this VM
	Nics []NicDevice `json:"nics"`
}

The list of network adapters

type NicIpStack

type NicIpStack struct {
	Common

	// Mac address of the interface
	Mac string `json:"mac"`
	// IP address(es) of the interface (CIDR)
	Ip []string `json:"ip,omitempty"`
	// DNS configuration of the interface
	Dns *DnsConfig `json:"dns,omitempty"`
	// WINS configuration of the interface
	Wins *WinsConfig `json:"wins,omitempty"`
	// DHCPv4 configuration of the interface
	Dhcp4 *DhcpConfig `json:"dhcp4,omitempty"`
	// DHCPv6 configuration of the interface
	Dhcp6 *DhcpConfig `json:"dhcp6,omitempty"`
}

Information about a NIC

type NicIpStackAll

type NicIpStackAll struct {
	Common

	Nics   []NicIpStack `json:"nics,omitempty"`
	Routes []RouteEntry `json:"routes,omitempty"`
	// Global DNS configuration
	Dns *DnsConfig `json:"dns,omitempty"`
	// Global WINS configuration
	Wins *WinsConfig `json:"wins,omitempty"`
	// Global DHCPv4 configuration
	Dhcpv4 *DhcpConfig `json:"dhcpv4,omitempty"`
	// Global DHCPv6 configuration
	Dhcpv6 *DhcpConfig `json:"dhcpv6,omitempty"`
}

Information about all NICs

type Portforward

type Portforward struct {
	Common

	Port     int               `json:"port"`
	Protocol string            `json:"protocol"`
	Desc     string            `json:"desc"`
	Guest    *PortforwardGuest `json:"guest"`
}

The port forwarding

type PortforwardGuest

type PortforwardGuest struct {
	Common

	Ip   string `json:"ip"`
	Port int    `json:"port"`
}

type PortforwardParameter

type PortforwardParameter struct {
	Common

	GuestIp   string `json:"guestIp"`
	GuestPort int    `json:"guestPort"`
	Desc      string `json:"desc,omitempty"`
}

type Portforwards

type Portforwards struct {
	Common

	Num int `json:"num"`
	// The list of port forwardings
	PortForwardings []Portforward `json:"port_forwardings"`
}

The list of port forwarding

type RouteEntry

type RouteEntry struct {
	Common

	Dest      string `json:"dest"`
	Prefix    int    `json:"prefix"`
	Nexthop   string `json:"nexthop,omitempty"`
	Interface int    `json:"interface"`
	Type      int    `json:"type"`
	Metric    int    `json:"metric"`
}

Routing entry

type SharedFolder

type SharedFolder struct {
	Common

	// ID of folder which be mounted to the host
	FolderId string `json:"folder_id"`
	// Path of the host shared folder
	HostPath string `json:"host_path"`
	// The flags property specifies how the folder will be accessed by the VM. There is only one flag supported which is \"4\" and means read/write access.
	Flags int `json:"flags"`
}

type SharedFolderParameter

type SharedFolderParameter struct {
	Common

	// Path of the host shared folder
	HostPath string `json:"host_path"`
	// The flags property specifies how the folder will be accessed by the VM. There is only one flag supported which is \"4\" and means read/write access.
	Flags int `json:"flags"`
}

type SharedFolders

type SharedFolders []SharedFolder

The shared folders mounted to this VM

type VmApplianceView

type VmApplianceView struct {
	Common

	Author        string `json:"author,omitempty"`
	Version       string `json:"version,omitempty"`
	Port          int    `json:"port,omitempty"`
	ShowAtPowerOn string `json:"showAtPowerOn,omitempty"`
}

type VmCloneParameter

type VmCloneParameter struct {
	Common

	// New VM name
	Name string `json:"name"`
	// Existing VM ID to clone.
	ParentId string `json:"parentId"`
}

type VmConnectedDevice

type VmConnectedDevice struct {
	Common

	Index            int    `json:"index,omitempty"`
	StartConnected   string `json:"startConnected,omitempty"`
	ConnectionStatus int    `json:"connectionStatus,omitempty"`
	DevicePath       string `json:"devicePath,omitempty"`
}

type VmConnectedDeviceList

type VmConnectedDeviceList struct {
	Common

	Num     int                 `json:"num,omitempty"`
	Devices []VmConnectedDevice `json:"devices,omitempty"`
}

type VmGuestIsolation

type VmGuestIsolation struct {
	Common

	CopyDisabled  string `json:"copyDisabled,omitempty"`
	DndDisabled   string `json:"dndDisabled,omitempty"`
	HgfsDisabled  string `json:"hgfsDisabled,omitempty"`
	PasteDisabled string `json:"pasteDisabled,omitempty"`
}

type VmInformation

type VmInformation struct {
	Common

	Id     string `json:"id"`
	Cpu    *Vmcpu `json:"cpu,omitempty"`
	Memory int    `json:"memory,omitempty"`
}

type VmParameter

type VmParameter struct {
	Common

	Processors int `json:"processors,omitempty"`
	Memory     int `json:"memory,omitempty"`
}

type VmPowerOperation

type VmPowerOperation string
const (
	VM_ON       VmPowerOperation = "on"
	VM_OFF      VmPowerOperation = "off"
	VM_SHUTDOWN VmPowerOperation = "shutdown"
	VM_SUSPEND  VmPowerOperation = "suspend"
	VM_PAUSE    VmPowerOperation = "pause"
	VM_UNPAUSE  VmPowerOperation = "unpause"
)

List of VMPowerOperation

type VmPowerState

type VmPowerState struct {
	Common

	PowerState string `json:"power_state"`
}

type VmRegisterParameter

type VmRegisterParameter struct {
	Common

	// Register VM name
	Name string `json:"name,omitempty"`
	// Register VM path
	Path string `json:"path,omitempty"`
}

type VmRegistrationInformation

type VmRegistrationInformation struct {
	Common

	// Registered VM name id
	Id string `json:"id,omitempty"`
	// Registered VM path
	Path string `json:"path,omitempty"`
}

type VmRemoteVnc

type VmRemoteVnc struct {
	Common

	VNCEnabled string `json:"VNCEnabled,omitempty"`
	VNCPort    int    `json:"VNCPort,omitempty"`
}

type VmRestrictionsInformation

type VmRestrictionsInformation struct {
	Common

	Id string `json:"id"`
	// The organization manages the VM
	ManagedOrg          string                 `json:"managedOrg,omitempty"`
	Integrityconstraint string                 `json:"integrityconstraint,omitempty"`
	Cpu                 *Vmcpu                 `json:"cpu,omitempty"`
	Memory              int                    `json:"memory,omitempty"`
	ApplianceView       *VmApplianceView       `json:"applianceView,omitempty"`
	CddvdList           *VmConnectedDeviceList `json:"cddvdList,omitempty"`
	FloopyList          *VmConnectedDeviceList `json:"floopyList,omitempty"`
	FirewareType        int                    `json:"firewareType,omitempty"`
	GuestIsolation      *VmGuestIsolation      `json:"guestIsolation,omitempty"`
	Niclist             *NicDevices            `json:"niclist,omitempty"`
	ParallelPortList    *VmConnectedDeviceList `json:"parallelPortList,omitempty"`
	SerialPortList      *VmConnectedDeviceList `json:"serialPortList,omitempty"`
	UsbList             *VmUsbList             `json:"usbList,omitempty"`
	RemoteVNC           *VmRemoteVnc           `json:"remoteVNC,omitempty"`
}

type VmUsbDevice

type VmUsbDevice struct {
	Common

	Index       int    `json:"index,omitempty"`
	Connected   string `json:"connected,omitempty"`
	BackingInfo string `json:"backingInfo,omitempty"`
	BackingType int    `json:"BackingType,omitempty"`
}

type VmUsbList

type VmUsbList struct {
	Common

	Num        int           `json:"num,omitempty"`
	UsbDevices []VmUsbDevice `json:"usbDevices,omitempty"`
}

type Vmcpu

type Vmcpu struct {
	Common

	Processors int `json:"processors,omitempty"`
}

The CPU information of VM

type Vmid

type Vmid struct {
	Common

	// ID of the VM
	Id string `json:"id"`
	// Path of the VM
	Path string `json:"path"`
}

type WinsConfig

type WinsConfig struct {
	Common

	Primary   string `json:"primary"`
	Secondary string `json:"secondary"`
}

WINS configuration

Jump to

Keyboard shortcuts

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