solusvm

package
v0.0.0-...-dd062b7 Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2018 License: Apache-2.0 Imports: 14 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

type API struct {
	Url      string
	ApiId    string
	ApiKey   string
	Insecure bool // InsecureSkipVerify true in tls.Config
}

func (*API) VmAddAddress

func (this *API) VmAddAddress(vmIdentification int) error

func (*API) VmConsole

func (this *API) VmConsole(vmIdentification int) (*APIVmConsoleResponse, error)

func (*API) VmCreate

func (this *API) VmCreate(virtType string, nodeGroup string, hostname string, imageIdentification string, memory int, diskspace int, cpu int) (int, string, error)

func (*API) VmDelete

func (this *API) VmDelete(vmIdentification int) error

func (*API) VmDiskSwap

func (this *API) VmDiskSwap(vmIdentification int) error

func (*API) VmHostname

func (this *API) VmHostname(vmIdentification int, hostname string) error

func (*API) VmInfo

func (this *API) VmInfo(vmIdentification int) (*APIVmInfoResponse, error)

func (*API) VmReboot

func (this *API) VmReboot(vmIdentification int) error

func (*API) VmReimage

func (this *API) VmReimage(vmIdentification int, imageIdentification string) error

func (*API) VmRemoveAddress

func (this *API) VmRemoveAddress(vmIdentification int, ip string) error

func (*API) VmResizeCpu

func (this *API) VmResizeCpu(vmIdentification int, cpu int) error

func (*API) VmResizeDisk

func (this *API) VmResizeDisk(vmIdentification int, hdd int) error

func (*API) VmResizeMemory

func (this *API) VmResizeMemory(vmIdentification int, memory int) error

func (*API) VmStart

func (this *API) VmStart(vmIdentification int) error

func (*API) VmStop

func (this *API) VmStop(vmIdentification int) error

func (*API) VmTunTap

func (this *API) VmTunTap(vmIdentification int, enable bool) error

func (*API) VmVnc

func (this *API) VmVnc(vmIdentification int) (*APIVmVncResponse, error)

type APIGenericResponse

type APIGenericResponse struct {
	XMLName xml.Name `xml:"root"`
	Status  string   `xml:"status"`
	Message string   `xml:"statusmsg"`
}

type APIVmConsoleResponse

type APIVmConsoleResponse struct {
	XMLName  xml.Name `xml:"root"`
	Ip       string   `xml:"consoleip"`
	Port     string   `xml:"consoleport"`
	Username string   `xml:"consoleusername"`
	Password string   `xml:"consolepassword"`
}

type APIVmCreateResponse

type APIVmCreateResponse struct {
	XMLName      xml.Name `xml:"root"`
	VmId         string   `xml:"vserverid"`
	RootPassword string   `xml:"rootpassword"`
}

type APIVmInfoResponse

type APIVmInfoResponse struct {
	XMLName     xml.Name `xml:"root"`
	Ip          string   `xml:"mainipaddress"`
	Ips         string   `xml:"ipaddresses"`
	InternalIps string   `xml:"internalips"`
	State       string   `xml:"state"`
	Bandwidth   string   `xml:"bandwidth"`
}

type APIVmVncResponse

type APIVmVncResponse struct {
	XMLName  xml.Name `xml:"root"`
	Ip       string   `xml:"vncip"`
	Port     string   `xml:"vncport"`
	Password string   `xml:"vncpassword"`
}

type ConsoleParams

type ConsoleParams struct {
	Frame    lobster.FrameParams
	Host     string
	Port     string
	Username string
	Password string
}

type SolusVM

type SolusVM struct {
	VirtType  string
	NodeGroup string
	Api       *API
	// contains filtered or unexported fields
}

func (*SolusVM) BandwidthAccounting

func (this *SolusVM) BandwidthAccounting(vm *lobster.VirtualMachine) int64

func (*SolusVM) ImageList

func (this *SolusVM) ImageList() ([]*lobster.Image, error)

func (*SolusVM) VmAction

func (this *SolusVM) VmAction(vm *lobster.VirtualMachine, action string, value string) error

func (*SolusVM) VmAddAddress

func (this *SolusVM) VmAddAddress(vm *lobster.VirtualMachine) error

func (*SolusVM) VmAddresses

func (this *SolusVM) VmAddresses(vm *lobster.VirtualMachine) ([]*lobster.IpAddress, error)

func (*SolusVM) VmCreate

func (this *SolusVM) VmCreate(vm *lobster.VirtualMachine, options *lobster.VMIVmCreateOptions) (string, error)

func (*SolusVM) VmDelete

func (this *SolusVM) VmDelete(vm *lobster.VirtualMachine) error

func (*SolusVM) VmInfo

func (this *SolusVM) VmInfo(vm *lobster.VirtualMachine) (*lobster.VmInfo, error)

func (*SolusVM) VmReboot

func (this *SolusVM) VmReboot(vm *lobster.VirtualMachine) error

func (*SolusVM) VmReimage

func (this *SolusVM) VmReimage(vm *lobster.VirtualMachine, imageIdentification string) error

func (*SolusVM) VmRemoveAddress

func (this *SolusVM) VmRemoveAddress(vm *lobster.VirtualMachine, ip string, privateip string) error

func (*SolusVM) VmRename

func (this *SolusVM) VmRename(vm *lobster.VirtualMachine, name string) error

func (*SolusVM) VmResize

func (this *SolusVM) VmResize(vm *lobster.VirtualMachine, plan *lobster.Plan) error

func (*SolusVM) VmSetRdns

func (this *SolusVM) VmSetRdns(vm *lobster.VirtualMachine, ip string, hostname string) error

func (*SolusVM) VmStart

func (this *SolusVM) VmStart(vm *lobster.VirtualMachine) error

func (*SolusVM) VmStop

func (this *SolusVM) VmStop(vm *lobster.VirtualMachine) error

func (*SolusVM) VmVnc

func (this *SolusVM) VmVnc(vm *lobster.VirtualMachine) (string, error)

Jump to

Keyboard shortcuts

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