Documentation ¶
Index ¶
- Variables
- type CfgVm
- type Client
- type Id
- type JobError
- type JobResponse
- type JobService
- type KeyValuePair
- type Vd
- type VdService
- type Vdm
- type VdmService
- type Vm
- type VmService
- func (v *VmService) CloneVm(cloneVmId string, vmCloneDefinitionId string, vm Vm, cfgVm CfgVm) (*string, error)
- func (v *VmService) CreateVm(vm Vm, cfgVm CfgVm) (*string, error)
- func (v *VmService) DeleteVm(vmId string) error
- func (v *VmService) Read(id string) (*Vm, error)
- func (v *VmService) SendMessageToVm(vmId string, cfgVm CfgVm) error
- func (v *VmService) SendRootPasswordToVm(vmId string, cfgVm CfgVm) error
- func (v *VmService) Start(id string) error
- func (v *VmService) Stop(id string) error
- func (v *VmService) UpdateVm(vmId string, vm Vm) error
- type Vmcd
- type VmcdService
- type Vmcnm
- type VmcnmService
- type Vmcsm
- type VmcsmService
- type Vn
- type VnService
Constants ¶
This section is empty.
Variables ¶
View Source
var ListVdm []Vdm
Functions ¶
This section is empty.
Types ¶
type CfgVm ¶
type CfgVm struct { NetworkId string SendMessages *[]KeyValuePair RootPassword *[]KeyValuePair }
type Client ¶
type Client struct { User string Password string BaseURL *url.URL Vms *VmService Vmcds *VmcdService Vmcsms *VmcsmService Vmcnms *VmcnmService Vns *VnService Vds *VdService Vdms *VdmService Jobs *JobService // contains filtered or unexported fields }
type JobResponse ¶
type JobResponse struct { Id *Id `json:"id"` Done bool `json:"done,omitempty"` ResultId *Id `json:"resultId,omitempty"` ResourceGroupIds *[]Id `json:"resourceGroupIds,omitempty"` SummaryDone bool `json:"summaryDone,omitempty"` JobGroup bool `json:"jobGroup,omitempty"` JobRunState string `json:"jobRunState,omitempty"` JobSummaryState string `json:"jobSummaryState,omitempty"` AbortedByUser string `json:"abortedByUser,omitempty"` ExtraInfo string `json:"extraInfo,omitempty"` Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` Locked bool `json:"locked,omitempty"` ReadOnly bool `json:"readOnly,omitempty"` Generation int `json:"generation,omitempty"` ProgressMessage string `json:"progressMessage,omitempty"` LatestSummaryProgressMessage string `json:"latestSummaryProgressMessage,omitempty"` StartTime int64 `json:"startTime,omitempty"` EndTime int64 `json:"endTime,omitempty"` ParentJobId *Id `json:"parentJobId,omitempty"` ChildJobIds *[]Id `json:"childJobIds,omitempty"` Error *JobError `json:"error,omitempty"` User string `json:"user,omitempty"` WsErrorCode string `json:"wsErrorCode,omitempty"` }
type JobService ¶
type JobService struct {
// contains filtered or unexported fields
}
func (*JobService) Read ¶
func (j *JobService) Read(id string) (*JobResponse, error)
func (*JobService) Running ¶
func (j *JobService) Running(id string) bool
func (*JobService) WaitForJob ¶
func (j *JobService) WaitForJob(id string)
type KeyValuePair ¶
type Vd ¶
type Vd struct { DiskType string `json:"diskType,omitempty"` // "VIRTUAL_DISK", Size int `json:"size,omitempty"` //Bytes multiple of 4096 OnDiskSize int `json:"onDiskSize,omitempty"` Path string `json:"path,omitempty"` VmDiskMappingIds []*Id `json:"vmDiskMappingIds,omitempty"` RepositoryId *Id `json:"repositoryId,omitempty"` ImportFileName string `json:"importFileName,omitempty"` AbsolutePath string `json:"absolutePath,omitempty"` MountedPath string `json:"mountedPath,omitempty"` AssemblyVirtualDiskId *Id `json:"assemblyVirtualDiskId,omitempty"` Id *Id `json:"id,omitempty"` Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` Locked bool `json:"locked,omitempty"` //false, ReadOnly bool `json:"readOnly,omitempty"` //: false, Generation int `json:"generation,omitempty"` /*"userData" : [ { "key" : "...", "value" : "..." }, ... ],*/ ResourceGroupIds []*Id `json:"resourceGroupIds,omitempty"` }
type VdService ¶
type VdService struct {
// contains filtered or unexported fields
}
type Vdm ¶
type Vdm struct { VmId *Id `json:"vmId,omitempty"` VirtualDiskId *Id `json:"virtualDiskId,omitempty"` DiskTarget int `json:"diskTarget"` EmulatedBlockDevice bool `json:"emulatedBlockDevice,omitempty"` // false, StorageElementId *Id `json:"storageElementId,omitempty"` DiskWriteMode string `json:"diskWriteMode,omitempty"` // "READ_ONLY",READ_WRITE Id *Id `json:"id,omitempty"` Name string `json:"name,omitempty"` //: "...", Description string `json:"description,omitempty"` // : "...", Locked bool `json:"locked,omitempty"` // false, ReadOnly bool `json:"readOnly,omitempty"` //false, Generation int `json:"generation,omitempty"` ResourceGroupIds *[]Id `json:"resourceGroupIds,omitempty"` //" : [ { }, ... ] }
vmDiskMapping element The VmDiskMapping object contains the relationships of the VirtualDisk and StorageElement for a Vm.
type VdmService ¶
type VdmService struct {
// contains filtered or unexported fields
}
type Vm ¶
type Vm struct { Id *Id `json:"id,omitempty"` Name string `json:"name,omitempty"` //The following fields of the new Vm are optional: //BootOrder []string CpuCount int `json:"cpuCount,omitempty"` CpuCountLimit int `json:"cpuCountLimit,omitempty"` CpuPriority int `json:"cpuPriority,omitempty"` CpuUtilizationCap int `json:"cpuUtilizationCap,omitempty"` HighAvailability bool `json:"highAvailability,omitempty"` HugePagesEnabled bool `json:"hugePagesEnabled,omitempty"` KeymapName string `json:"keymapName,omitempty"` Memory int `json:"memory,omitempty"` MemoryLimit int `json:"memoryLimit,omitempty"` NetworkInstallPath string `json:"networkInstallPath,omitempty"` OsType string `json:"osType,omitempty"` VmDomainType string `json:"vmDomainType,omitempty"` VmMouseType string `json:"vmMouseType,omitempty"` VmRunState string `json:"vmRunState,omitempty"` VmStartPolicy string `json:"vmStartPolicy,omitempty"` SslVncPort int `json:"sslVncPort,omitempty"` SslTtyPort string `json:"sslTtyPort,omitempty"` AffinityGroupIds []int `json:"affinityGroupIds,omitempty"` OsVersion string `json:"osVersion,omitempty"` KernelVersion string `json:"kernelVersion,omitempty"` GuestDriverVersion string `json:"guestDriverVersion,omitempty"` VmApiVersion string `json:"vmApiVersion,omitempty"` CurrentMemory int `json:"currentMemory,omitempty"` CurrentCpuCount int `json:"currentCpuCount,omitempty"` CurrentDomainId int `json:"currentDomainId,omitempty"` VmConfigFileAbsolutePath string `json:"vmConfigFileAbsolutePath,omitempty"` VmConfigFileMountedPath string `json:"vmConfigFileMountedPath,omitempty"` Architecture string `json:"architecture,omitempty"` VmDiskMappingIds *[]Id `json:"vmDiskMappingIds,omitempty"` VirtualNicIds *[]Id `json:"virtualNicIds,omitempty"` RepositoryId *Id `json:"repositoryId,omitempty"` ServerPoolId *Id `json:"serverPoolId,omitempty"` ServerId *Id `json:"serverId,omitempty"` Generation int `json:"generation,omitempty"` }
type VmService ¶
type VmService struct {
// contains filtered or unexported fields
}
func (*VmService) SendMessageToVm ¶
func (*VmService) SendRootPasswordToVm ¶
type Vmcd ¶
type Vmcd struct { VmId *Id `json:"vmId,omitempty"` VmCloneNetworkMappingIds *[]Id `json:"vmCloneNetworkMappingIds,omitempty"` VmCloneStorageMappingIds *[]Id `json:"vmCloneStorageMappingIds,omitempty"` Id *Id `json:"id,omitempty"` Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` Locked bool `json:"locked,imitempty"` ReadOnly bool `json:"readOnly,omitempty"` Generation int `json:"generation,omitempty"` ResourceGroupIds *[]Id `json:"resourceGroupIds,omitempty"` }
type VmcdService ¶
type VmcdService struct {
// contains filtered or unexported fields
}
type Vmcnm ¶
type Vmcnm struct { NetworkId *Id `json:"networkId,omitempty"` VmCloneDefinitionId *Id `json:"vmCloneDefinitionId,omitempty"` VirtualNicId *Id `json:"virtualNicId,omitempty"` Id *Id `json:"id,omitempty"` Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` Locked bool `json:"locked,imitempty"` ReadOnly bool `json:"readOnly,omitempty"` Generation int `json:"generation,omitempty"` ResourceGroupIds *[]Id `json:"resourceGroupIds,omitempty"` }
type VmcnmService ¶
type VmcnmService struct {
// contains filtered or unexported fields
}
func (*VmcnmService) Create ¶
func (v *VmcnmService) Create(vmCloneDefinitionId string, vmcnm Vmcnm) (*string, error)
type Vmcsm ¶
type Vmcsm struct { VmDiskMappingId *Id `json:"vmDiskMappingId,omitempty"` VmCloneDefinitionId *Id `json:"vmCloneDefinitionId,omitempty"` RepositoryId *Id `json:"repositoryId,omitempty"` StorageArrayId *Id `json:"storageArrayId,omitempty"` StorageElementId *Id `json:",omitempty"` Id *Id `json:"id,omitempty"` CloneType string `json:"cloneType,omitempty"` Name string `json:"name,omitempty"` Description string `json:"description,omitempty"` Locked bool `json:"locked,imitempty"` ReadOnly bool `json:"readOnly,omitempty"` Generation int `json:"generation,omitempty"` ResourceGroupIds *[]Id `json:"resourceGroupIds,omitempty"` }
type VmcsmService ¶
type VmcsmService struct {
// contains filtered or unexported fields
}
func (*VmcsmService) Create ¶
func (v *VmcsmService) Create(vmCloneDefinitionId string, vmcsm Vmcsm) (*string, error)
type Vn ¶
type Vn struct { MacAddress string `json:"macAddress,omitempty"` //IpAddresses *[]Id `json:"ipAddresses,omitempty"` //InterfaceName string `json:"interfaceName,omitempty"` VmId *Id `json:"vmId,omitempty"` NetworkId *Id `json:"networkId,omitempty"` Id *Id `json:"id,omitempty"` Name string `json:"name,omitempty"` //Description string `json:description,omitempty"` //Locked bool `json:locked,omitempty"` //ReadOnly bool `json:readOnly,omitempty"` Generation int `json:"generation,omitempty"` }
Click to show internal directories.
Click to hide internal directories.