Documentation ¶
Index ¶
- Constants
- Variables
- func GetBucketName(regionId string, imageId string) string
- type Address
- type Attachment
- type CtyunClientConfig
- type CtyunTags
- type DiskDetails
- type FixedIP
- type FlavorObj
- type Image
- type InstanceDetails
- type Metadata
- type PrivateIP
- type Profile
- type PublicIP
- type PublicP
- type PublicipInfo
- type ResourceConfigMap
- type SBandwidth
- type SCrmUser
- type SCtyunClient
- func (client *SCtyunClient) DoGet(apiName string, queries map[string]string) (jsonutils.JSONObject, error)
- func (client *SCtyunClient) DoPost(apiName string, params map[string]jsonutils.JSONObject) (jsonutils.JSONObject, error)
- func (self *SCtyunClient) FetchProjects() ([]SProject, error)
- func (self *SCtyunClient) GetAccessEnv() string
- func (client *SCtyunClient) GetAccountId() string
- func (self *SCtyunClient) GetCapabilities() []string
- func (self *SCtyunClient) GetCloudRegionExternalIdPrefix() string
- func (self *SCtyunClient) GetIProjects() ([]cloudprovider.ICloudProject, error)
- func (self *SCtyunClient) GetIRegionById(id string) (cloudprovider.ICloudRegion, error)
- func (self *SCtyunClient) GetIRegions() []cloudprovider.ICloudRegion
- func (self *SCtyunClient) GetRegion(regionId string) *SRegion
- func (self *SCtyunClient) GetRegions() []SRegion
- func (self *SCtyunClient) GetSubAccounts() ([]cloudprovider.SSubAccount, error)
- type SDisk
- func (self *SDisk) CreateISnapshot(ctx context.Context, name string, desc string) (cloudprovider.ICloudSnapshot, error)
- func (self *SDisk) Delete(ctx context.Context) error
- func (self *SDisk) GetAccessPath() string
- func (self *SDisk) GetBillingType() string
- func (self *SDisk) GetCacheMode() string
- func (self *SDisk) GetCreatedAt() time.Time
- func (self *SDisk) GetDiskDetails() (*DiskDetails, error)
- func (self *SDisk) GetDiskFormat() string
- func (self *SDisk) GetDiskSizeMB() int
- func (self *SDisk) GetDiskType() string
- func (self *SDisk) GetDriver() string
- func (self *SDisk) GetExpiredAt() time.Time
- func (self *SDisk) GetExtSnapshotPolicyIds() ([]string, error)
- func (self *SDisk) GetFsFormat() string
- func (self *SDisk) GetGlobalId() string
- func (self *SDisk) GetISnapshot(idStr string) (cloudprovider.ICloudSnapshot, error)
- func (self *SDisk) GetISnapshots() ([]cloudprovider.ICloudSnapshot, error)
- func (self *SDisk) GetIStorage() (cloudprovider.ICloudStorage, error)
- func (self *SDisk) GetIStorageId() string
- func (self *SDisk) GetId() string
- func (self *SDisk) GetIsAutoDelete() bool
- func (self *SDisk) GetIsNonPersistent() bool
- func (self *SDisk) GetMountpoint() string
- func (self *SDisk) GetName() string
- func (self *SDisk) GetProjectId() string
- func (self *SDisk) GetStatus() string
- func (self *SDisk) GetSysTags() map[string]string
- func (self *SDisk) GetTemplateId() string
- func (self *SDisk) IsEmulated() bool
- func (self *SDisk) Rebuild(ctx context.Context) error
- func (self *SDisk) Refresh() error
- func (self *SDisk) Reset(ctx context.Context, snapshotId string) (string, error)
- func (self *SDisk) Resize(ctx context.Context, newSizeMB int64) error
- type SDiskBackup
- func (self *SDiskBackup) Delete() error
- func (self *SDiskBackup) GetDiskId() string
- func (self *SDiskBackup) GetDiskType() string
- func (self *SDiskBackup) GetGlobalId() string
- func (self *SDiskBackup) GetId() string
- func (self *SDiskBackup) GetName() string
- func (self *SDiskBackup) GetProjectId() string
- func (self *SDiskBackup) GetSizeMb() int32
- func (self *SDiskBackup) GetStatus() string
- func (self *SDiskBackup) IsEmulated() bool
- func (self *SDiskBackup) Refresh() error
- type SDiskBacupPolicy
- func (self *SDiskBacupPolicy) GetGlobalId() string
- func (self *SDiskBacupPolicy) GetId() string
- func (self *SDiskBacupPolicy) GetName() string
- func (self *SDiskBacupPolicy) GetProjectId() string
- func (self *SDiskBacupPolicy) GetRepeatWeekdays() ([]int, error)
- func (self *SDiskBacupPolicy) GetRetentionDays() int
- func (self *SDiskBacupPolicy) GetStatus() string
- func (self *SDiskBacupPolicy) GetTimePoints() ([]int, error)
- func (self *SDiskBacupPolicy) IsActivated() bool
- func (self *SDiskBacupPolicy) IsEmulated() bool
- func (self *SDiskBacupPolicy) Refresh() error
- type SDiskDetails
- type SEip
- func (self *SEip) Associate(conf *cloudprovider.AssociateConfig) error
- func (self *SEip) ChangeBandwidth(bw int) error
- func (self *SEip) Delete() error
- func (self *SEip) Dissociate() error
- func (self *SEip) GetAssociationExternalId() string
- func (self *SEip) GetAssociationType() string
- func (self *SEip) GetBandwidth() int
- func (self *SEip) GetBillingType() string
- func (self *SEip) GetCreatedAt() time.Time
- func (self *SEip) GetExpiredAt() time.Time
- func (self *SEip) GetGlobalId() string
- func (self *SEip) GetINetworkId() string
- func (self *SEip) GetId() string
- func (self *SEip) GetInternetChargeType() string
- func (self *SEip) GetIpAddr() string
- func (self *SEip) GetMode() string
- func (self *SEip) GetName() string
- func (self *SEip) GetProjectId() string
- func (self *SEip) GetStatus() string
- func (self *SEip) IsEmulated() bool
- func (self *SEip) Refresh() error
- type SHost
- func (self *SHost) CreateVM(desc *cloudprovider.SManagedVMCreateConfig) (cloudprovider.ICloudVM, error)
- func (self *SHost) GetAccessIp() string
- func (self *SHost) GetAccessMac() string
- func (self *SHost) GetCpuCount() int
- func (self *SHost) GetCpuDesc() string
- func (self *SHost) GetCpuMhz() int
- func (self *SHost) GetEnabled() bool
- func (self *SHost) GetGlobalId() string
- func (self *SHost) GetHostStatus() string
- func (self *SHost) GetHostType() string
- func (self *SHost) GetIHostNics() ([]cloudprovider.ICloudHostNetInterface, error)
- func (self *SHost) GetIStorageById(id string) (cloudprovider.ICloudStorage, error)
- func (self *SHost) GetIStorages() ([]cloudprovider.ICloudStorage, error)
- func (self *SHost) GetIVMById(id string) (cloudprovider.ICloudVM, error)
- func (self *SHost) GetIVMs() ([]cloudprovider.ICloudVM, error)
- func (self *SHost) GetIWires() ([]cloudprovider.ICloudWire, error)
- func (self *SHost) GetId() string
- func (self *SHost) GetIsMaintenance() bool
- func (self *SHost) GetMemSizeMB() int
- func (self *SHost) GetName() string
- func (self *SHost) GetNodeCount() int8
- func (self *SHost) GetSN() string
- func (self *SHost) GetStatus() string
- func (self *SHost) GetStorageSizeMB() int
- func (self *SHost) GetStorageType() string
- func (self *SHost) GetSysInfo() jsonutils.JSONObject
- func (self *SHost) GetVersion() string
- func (self *SHost) IsEmulated() bool
- func (self *SHost) Refresh() error
- type SImage
- func (self *SImage) Delete(ctx context.Context) error
- func (self *SImage) GetBios() cloudprovider.TBiosType
- func (self *SImage) GetCreateTime() time.Time
- func (self *SImage) GetCreatedAt() time.Time
- func (self *SImage) GetFullOsName() string
- func (self *SImage) GetGlobalId() string
- func (self *SImage) GetIStoragecache() cloudprovider.ICloudStoragecache
- func (self *SImage) GetId() string
- func (self *SImage) GetImageFormat() string
- func (self *SImage) GetImageStatus() string
- func (self *SImage) GetImageType() cloudprovider.TImageType
- func (self *SImage) GetMinOsDiskSizeGb() int
- func (self *SImage) GetMinRamSizeMb() int
- func (self *SImage) GetName() string
- func (self *SImage) GetOsArch() string
- func (self *SImage) GetOsDist() string
- func (self *SImage) GetOsLang() string
- func (self *SImage) GetOsType() cloudprovider.TOsType
- func (self *SImage) GetOsVersion() string
- func (self *SImage) GetSizeByte() int64
- func (self *SImage) GetStatus() string
- func (self *SImage) IsEmulated() bool
- func (self *SImage) Refresh() error
- type SInstance
- func (self *SInstance) AssignSecurityGroup(secgroupId string) error
- func (self *SInstance) AttachDisk(ctx context.Context, diskId string) error
- func (self *SInstance) ChangeConfig(ctx context.Context, config *cloudprovider.SManagedVMChangeConfig) error
- func (self *SInstance) DeleteVM(ctx context.Context) error
- func (self *SInstance) DeployVM(ctx context.Context, name string, username string, password string, ...) error
- func (self *SInstance) DetachDisk(ctx context.Context, diskId string) error
- func (self *SInstance) GetBillingType() string
- func (self *SInstance) GetBios() cloudprovider.TBiosType
- func (self *SInstance) GetBootOrder() string
- func (self *SInstance) GetCreatedAt() time.Time
- func (self *SInstance) GetDetails() (*InstanceDetails, error)
- func (self *SInstance) GetError() error
- func (self *SInstance) GetExpiredAt() time.Time
- func (self *SInstance) GetFullOsName() string
- func (self *SInstance) GetGlobalId() string
- func (self *SInstance) GetHostname() string
- func (self *SInstance) GetHypervisor() string
- func (self *SInstance) GetIDisks() ([]cloudprovider.ICloudDisk, error)
- func (self *SInstance) GetIEIP() (cloudprovider.ICloudEIP, error)
- func (self *SInstance) GetIHost() cloudprovider.ICloudHost
- func (self *SInstance) GetINics() ([]cloudprovider.ICloudNic, error)
- func (self *SInstance) GetId() string
- func (self *SInstance) GetImage() (*SImage, error)
- func (self *SInstance) GetInstanceType() string
- func (self *SInstance) GetMachine() string
- func (self *SInstance) GetName() string
- func (self *SInstance) GetOsArch() string
- func (self *SInstance) GetOsDist() string
- func (self *SInstance) GetOsLang() string
- func (self *SInstance) GetOsType() cloudprovider.TOsType
- func (self *SInstance) GetOsVersion() string
- func (self *SInstance) GetProjectId() string
- func (self *SInstance) GetSecurityGroupIds() ([]string, error)
- func (self *SInstance) GetStatus() string
- func (self *SInstance) GetVNCInfo(input *cloudprovider.ServerVncInput) (*cloudprovider.ServerVncOutput, error)
- func (self *SInstance) GetVcpuCount() int
- func (self *SInstance) GetVdi() string
- func (self *SInstance) GetVga() string
- func (self *SInstance) GetVmemSizeMB() int
- func (self *SInstance) IsEmulated() bool
- func (self *SInstance) NextDeviceName() (string, error)
- func (self *SInstance) RebuildRoot(ctx context.Context, config *cloudprovider.SManagedVMRebuildRootConfig) (string, error)
- func (self *SInstance) Refresh() error
- func (self *SInstance) Renew(bc billing.SBillingCycle) error
- func (self *SInstance) SetSecurityGroups(secgroupIds []string) error
- func (self *SInstance) StartVM(ctx context.Context) error
- func (self *SInstance) StopVM(ctx context.Context, opts *cloudprovider.ServerStopOptions) error
- func (self *SInstance) UpdateUserData(userData string) error
- func (self *SInstance) UpdateVM(ctx context.Context, name string) error
- type SInstanceNic
- type SKeypair
- type SNetwork
- func (self *SNetwork) Delete() error
- func (self *SNetwork) GetAllocTimeoutSeconds() int
- func (self *SNetwork) GetGateway() string
- func (self *SNetwork) GetGlobalId() string
- func (self *SNetwork) GetIWire() cloudprovider.ICloudWire
- func (self *SNetwork) GetId() string
- func (self *SNetwork) GetIpEnd() string
- func (self *SNetwork) GetIpMask() int8
- func (self *SNetwork) GetIpStart() string
- func (self *SNetwork) GetIsPublic() bool
- func (self *SNetwork) GetName() string
- func (self *SNetwork) GetProjectId() string
- func (self *SNetwork) GetPublicScope() rbacutils.TRbacScope
- func (self *SNetwork) GetServerType() string
- func (self *SNetwork) GetStatus() string
- func (self *SNetwork) IsEmulated() bool
- func (self *SNetwork) Refresh() error
- type SOrder
- type SProject
- type SRegion
- func (self *SRegion) AddSecurityGroupRules(secGrpId string, rule cloudprovider.SecurityRule) error
- func (self *SRegion) ApplySnapshotPolicyToDisks(snapshotPolicyId string, diskId string) error
- func (self *SRegion) AssignSecurityGroup(vmId, securityGroupRuleId string) error
- func (self *SRegion) AssociateEip(publicIpId, networkCardId string) error
- func (self *SRegion) AttachDisk(vmId, volumeId, device string) (string, error)
- func (self *SRegion) BindingDiskBackupPolicy(policyId, resourceId, resourceType string) error
- func (self *SRegion) CancelSnapshotPolicyToDisks(snapshotPolicyId string, diskId string) error
- func (self *SRegion) ChangeBandwidthEip(name, publicIpId, sizeMb string) error
- func (self *SRegion) ChangeVMConfig(vmId, flavorId string) (string, error)
- func (self *SRegion) CreateDisk(zoneId, name, diskType, size string) (*SDisk, error)
- func (self *SRegion) CreateDiskBackup(name, volumeId, desc string) (string, error)
- func (self *SRegion) CreateDiskBackupPolicy(name, startTime, frequency, rententionNum, firstBackup, status string) error
- func (self *SRegion) CreateEIP(eip *cloudprovider.SEip) (cloudprovider.ICloudEIP, error)
- func (self *SRegion) CreateEip(zoneId, name, size, shareType, chargeType string) (*SEip, error)
- func (self *SRegion) CreateISecurityGroup(conf *cloudprovider.SecurityGroupCreateInput) (cloudprovider.ICloudSecurityGroup, error)
- func (self *SRegion) CreateIVpc(opts *cloudprovider.VpcCreateOptions) (cloudprovider.ICloudVpc, error)
- func (self *SRegion) CreateInstance(...) (string, error)
- func (self *SRegion) CreateNetwork(vpcId, zoneId, name, cidr, dhcpEnable string) (*SNetwork, error)
- func (self *SRegion) CreateSecurityGroup(vpcId, name string) (*SSecurityGroup, error)
- func (self *SRegion) CreateSecurityGroupRule(groupId, direction, ethertype, protocol, remoteIpPrefix string, ...) error
- func (self *SRegion) CreateSnapshotPolicy(*cloudprovider.SnapshotPolicyInput) (string, error)
- func (self *SRegion) CreateVpc(name, cidr string) (*SVpc, error)
- func (self *SRegion) DeleteDisk(volumeId string) (string, error)
- func (self *SRegion) DeleteDiskBackup(vbsId string) (string, error)
- func (self *SRegion) DeleteEip(publicIpId string) error
- func (self *SRegion) DeleteNetwork(vpcId, subnetId string) error
- func (self *SRegion) DeleteSecurityGroup(securityGroupId string) error
- func (self *SRegion) DeleteSecurityGroupRule(securityGroupRuleId string) error
- func (self *SRegion) DeleteSnapshotPolicy(policyId string) error
- func (self *SRegion) DeleteVM(vmId string) error
- func (self *SRegion) DeleteVpc(vpcId string) error
- func (self *SRegion) DetachDisk(vmId, volumeId, device string) (string, error)
- func (self *SRegion) DissociateEip(publicIpId string) error
- func (self *SRegion) FetchProjects() ([]SProject, error)
- func (region *SRegion) GetCapabilities() []string
- func (self *SRegion) GetClient() *SCtyunClient
- func (self *SRegion) GetCrmUser(t string, crmBizId string, accountId string) (*SCrmUser, error)
- func (self *SRegion) GetDisk(diskId string) (*SDisk, error)
- func (self *SRegion) GetDiskBackup(diskId string, backupId string) (*SDiskBackup, error)
- func (self *SRegion) GetDiskBackupPolices() ([]SDiskBacupPolicy, error)
- func (self *SRegion) GetDiskBackupPolicy(policyId string) (*SDiskBacupPolicy, error)
- func (self *SRegion) GetDiskBackups(diskId string) ([]SDiskBackup, error)
- func (self *SRegion) GetDiskDetailByDiskId(diskId string) (*DiskDetails, error)
- func (self *SRegion) GetDisks() ([]SDisk, error)
- func (self *SRegion) GetEip(eipId string) (*SEip, error)
- func (self *SRegion) GetEips() ([]SEip, error)
- func (self *SRegion) GetGeographicInfo() cloudprovider.SGeographicInfo
- func (self *SRegion) GetGlobalId() string
- func (self *SRegion) GetI18n() cloudprovider.SModelI18nTable
- func (self *SRegion) GetIDiskById(id string) (cloudprovider.ICloudDisk, error)
- func (self *SRegion) GetIEipById(id string) (cloudprovider.ICloudEIP, error)
- func (self *SRegion) GetIEips() ([]cloudprovider.ICloudEIP, error)
- func (self *SRegion) GetIHostById(id string) (cloudprovider.ICloudHost, error)
- func (self *SRegion) GetIHosts() ([]cloudprovider.ICloudHost, error)
- func (self *SRegion) GetISecurityGroupById(secgroupId string) (cloudprovider.ICloudSecurityGroup, error)
- func (self *SRegion) GetISecurityGroupByName(opts *cloudprovider.SecurityGroupFilterOptions) (cloudprovider.ICloudSecurityGroup, error)
- func (self *SRegion) GetISnapshotById(snapshotId string) (cloudprovider.ICloudSnapshot, error)
- func (self *SRegion) GetISnapshotPolicies() ([]cloudprovider.ICloudSnapshotPolicy, error)
- func (self *SRegion) GetISnapshotPolicyById(snapshotPolicyId string) (cloudprovider.ICloudSnapshotPolicy, error)
- func (self *SRegion) GetISnapshots() ([]cloudprovider.ICloudSnapshot, error)
- func (self *SRegion) GetIStorageById(id string) (cloudprovider.ICloudStorage, error)
- func (self *SRegion) GetIStoragecacheById(id string) (cloudprovider.ICloudStoragecache, error)
- func (self *SRegion) GetIStoragecaches() ([]cloudprovider.ICloudStoragecache, error)
- func (self *SRegion) GetIStorages() ([]cloudprovider.ICloudStorage, error)
- func (self *SRegion) GetIVMById(id string) (cloudprovider.ICloudVM, error)
- func (self *SRegion) GetIVpcById(id string) (cloudprovider.ICloudVpc, error)
- func (self *SRegion) GetIVpcs() ([]cloudprovider.ICloudVpc, error)
- func (self *SRegion) GetIZoneById(id string) (cloudprovider.ICloudZone, error)
- func (self *SRegion) GetIZones() ([]cloudprovider.ICloudZone, error)
- func (self *SRegion) GetId() string
- func (self *SRegion) GetImage(imageId string) (*SImage, error)
- func (self *SRegion) GetImages(imageType string) ([]SImage, error)
- func (self *SRegion) GetInstanceFlavors() ([]FlavorObj, error)
- func (self *SRegion) GetInstanceVNCUrl(vmId string) (string, error)
- func (self *SRegion) GetInstances(instanceId string) ([]SInstance, error)
- func (self *SRegion) GetJob(jobId string) (jsonutils.JSONObject, error)
- func (self *SRegion) GetKeypair(name string) (*SKeypair, error)
- func (self *SRegion) GetKeypairs() ([]SKeypair, int, error)
- func (self *SRegion) GetName() string
- func (self *SRegion) GetNetwork(subnetId string) (*SNetwork, error)
- func (self *SRegion) GetNetwroks(vpcId string) ([]SNetwork, error)
- func (self *SRegion) GetNics(vmId string) ([]SInstanceNic, error)
- func (self *SRegion) GetOrder(orderId string) ([]SOrder, error)
- func (self *SRegion) GetProvider() string
- func (self *SRegion) GetSecurityGroupDetails(groupId string) (*SSecurityGroup, error)
- func (self *SRegion) GetSecurityGroupRules(secgroupId string) ([]SSecurityGroupRule, error)
- func (self *SRegion) GetSecurityGroups(vpcId string) ([]SSecurityGroup, error)
- func (self *SRegion) GetStatus() string
- func (self *SRegion) GetVMById(vmId string) (*SInstance, error)
- func (self *SRegion) GetVMDetails(vmId string) (*InstanceDetails, error)
- func (self *SRegion) GetVMs() ([]SInstance, error)
- func (self *SRegion) GetVbsJob(jobId string) (jsonutils.JSONObject, error)
- func (self *SRegion) GetVolumeJob(jobId string) (jsonutils.JSONObject, error)
- func (self *SRegion) GetVpc(vpcId string) (*SVpc, error)
- func (self *SRegion) GetVpcs() ([]SVpc, error)
- func (self *SRegion) ImportKeypair(name, publicKey string) (*SKeypair, error)
- func (self *SRegion) IsEmulated() bool
- func (self *SRegion) RebuildVM(vmId, adminPass, keyName string) (string, error)
- func (self *SRegion) Refresh() error
- func (self *SRegion) RenewVM(vmId string, bc *billing.SBillingCycle) ([]string, error)
- func (self *SRegion) ResetVMPassword(vmId, password string) error
- func (self *SRegion) ResizeDisk(volumeId string, newSizeGB string) (string, error)
- func (self *SRegion) RestartVM(vmId string) error
- func (self *SRegion) RestoreDisk(volumeId, backupId string) (string, error)
- func (self *SRegion) StartVM(vmId string) error
- func (self *SRegion) StopVM(vmId string) error
- func (self *SRegion) SwitchVMOs(vmId, adminPass, keyName, imageRef string) (string, error)
- func (self *SRegion) UnBindDiskBackupPolicy(policyId, resourceId string) error
- func (self *SRegion) UnsignSecurityGroup(vmId, securityGroupRuleId string) error
- func (self *SRegion) UpdateSnapshotPolicy(*cloudprovider.SnapshotPolicyInput, string) error
- type SSecurityGroup
- func (self *SSecurityGroup) Delete() error
- func (self *SSecurityGroup) GetDescription() string
- func (self *SSecurityGroup) GetGlobalId() string
- func (self *SSecurityGroup) GetId() string
- func (self *SSecurityGroup) GetName() string
- func (self *SSecurityGroup) GetRules() ([]cloudprovider.SecurityRule, error)
- func (self *SSecurityGroup) GetSecurityRule(remoteRule SSecurityGroupRule) (cloudprovider.SecurityRule, error)
- func (self *SSecurityGroup) GetStatus() string
- func (self *SSecurityGroup) GetVpcId() string
- func (self *SSecurityGroup) IsEmulated() bool
- func (self *SSecurityGroup) Refresh() error
- func (self *SSecurityGroup) SyncRules(common, inAdds, outAdds, inDels, outDels []cloudprovider.SecurityRule) error
- type SSecurityGroupRule
- type SStorage
- func (self *SStorage) CreateIDisk(conf *cloudprovider.DiskCreateConfig) (cloudprovider.ICloudDisk, error)
- func (self *SStorage) GetCapacityMB() int64
- func (self *SStorage) GetCapacityUsedMB() int64
- func (self *SStorage) GetEnabled() bool
- func (self *SStorage) GetGlobalId() string
- func (self *SStorage) GetIDiskById(idStr string) (cloudprovider.ICloudDisk, error)
- func (self *SStorage) GetIDisks() ([]cloudprovider.ICloudDisk, error)
- func (self *SStorage) GetIStoragecache() cloudprovider.ICloudStoragecache
- func (self *SStorage) GetIZone() cloudprovider.ICloudZone
- func (self *SStorage) GetId() string
- func (self *SStorage) GetMediumType() string
- func (self *SStorage) GetMountPoint() string
- func (self *SStorage) GetName() string
- func (self *SStorage) GetStatus() string
- func (self *SStorage) GetStorageConf() jsonutils.JSONObject
- func (self *SStorage) GetStorageType() string
- func (self *SStorage) IsEmulated() bool
- func (self *SStorage) IsSysDiskStore() bool
- func (self *SStorage) Refresh() error
- type SStoragecache
- func (self *SStoragecache) CreateIImage(snapshotId, imageName, osType, imageDesc string) (cloudprovider.ICloudImage, error)
- func (self *SStoragecache) DownloadImage(userCred mcclient.TokenCredential, imageId string, extId string, path string) (jsonutils.JSONObject, error)
- func (self *SStoragecache) GetGlobalId() string
- func (self *SStoragecache) GetICloudImages() ([]cloudprovider.ICloudImage, error)
- func (self *SStoragecache) GetICustomizedCloudImages() ([]cloudprovider.ICloudImage, error)
- func (self *SStoragecache) GetIImageById(extId string) (cloudprovider.ICloudImage, error)
- func (self *SStoragecache) GetId() string
- func (self *SStoragecache) GetName() string
- func (self *SStoragecache) GetPath() string
- func (self *SStoragecache) GetStatus() string
- func (self *SStoragecache) IsEmulated() bool
- func (self *SStoragecache) Refresh() error
- func (self *SStoragecache) UploadImage(ctx context.Context, userCred mcclient.TokenCredential, ...) (string, error)
- type SVncInfo
- type SVpc
- func (self *SVpc) Delete() error
- func (self *SVpc) GetCidrBlock() string
- func (self *SVpc) GetGlobalId() string
- func (self *SVpc) GetIRouteTableById(routeTableId string) (cloudprovider.ICloudRouteTable, error)
- func (self *SVpc) GetIRouteTables() ([]cloudprovider.ICloudRouteTable, error)
- func (self *SVpc) GetISecurityGroups() ([]cloudprovider.ICloudSecurityGroup, error)
- func (self *SVpc) GetIWireById(wireId string) (cloudprovider.ICloudWire, error)
- func (self *SVpc) GetIWires() ([]cloudprovider.ICloudWire, error)
- func (self *SVpc) GetId() string
- func (self *SVpc) GetIsDefault() bool
- func (self *SVpc) GetName() string
- func (self *SVpc) GetRegion() cloudprovider.ICloudRegion
- func (self *SVpc) GetStatus() string
- func (self *SVpc) IsEmulated() bool
- func (self *SVpc) Refresh() error
- type SWire
- func (self *SWire) CreateINetwork(opts *cloudprovider.SNetworkCreateOptions) (cloudprovider.ICloudNetwork, error)
- func (self *SWire) GetBandwidth() int
- func (self *SWire) GetGlobalId() string
- func (self *SWire) GetINetworkById(netid string) (cloudprovider.ICloudNetwork, error)
- func (self *SWire) GetINetworks() ([]cloudprovider.ICloudNetwork, error)
- func (self *SWire) GetIVpc() cloudprovider.ICloudVpc
- func (self *SWire) GetIZone() cloudprovider.ICloudZone
- func (self *SWire) GetId() string
- func (self *SWire) GetName() string
- func (self *SWire) GetStatus() string
- func (self *SWire) IsEmulated() bool
- func (self *SWire) Refresh() error
- type SZone
- func (self *SZone) GetGlobalId() string
- func (self *SZone) GetI18n() cloudprovider.SModelI18nTable
- func (self *SZone) GetIHostById(id string) (cloudprovider.ICloudHost, error)
- func (self *SZone) GetIHosts() ([]cloudprovider.ICloudHost, error)
- func (self *SZone) GetIRegion() cloudprovider.ICloudRegion
- func (self *SZone) GetIStorageById(id string) (cloudprovider.ICloudStorage, error)
- func (self *SZone) GetIStorages() ([]cloudprovider.ICloudStorage, error)
- func (self *SZone) GetIWires() ([]cloudprovider.ICloudWire, error)
- func (self *SZone) GetId() string
- func (self *SZone) GetName() string
- func (self *SZone) GetStatus() string
- func (self *SZone) IsEmulated() bool
- func (self *SZone) Refresh() error
- type ScheduledPolicy
- type SecurityGroup
- type SecurityGroupID
- type Volume
Constants ¶
const ( CTYUN_API_HOST = "https://api.ctyun.cn" CLOUD_PROVIDER_CTYUN = api.CLOUD_PROVIDER_CTYUN CLOUD_PROVIDER_CTYUN_CN = "天翼云" CLOUD_PROVIDER_CTYUN_EN = "Ctyun" CTYUN_DEFAULT_REGION = "cn-bj4" CTYUN_API_VERSION = "2019-11-22" )
const ( ImageOwnerPublic string = "gold" // 公共镜像:gold ImageOwnerSelf string = "private" // 私有镜像:private )
Variables ¶
var LatitudeAndLongitude = map[string]cloudprovider.SGeographicInfo{ "cn-beijing1": {Latitude: 39.997743, Longitude: 116.304542, City: api.CITY_BEI_JING, CountryCode: api.COUNTRY_CODE_CN}, "cn-hz1": {Latitude: 30.274084, Longitude: 120.155067, City: api.CITY_HANG_ZHOU, CountryCode: api.COUNTRY_CODE_CN}, "cn-gslz1": {Latitude: 36.0613769373, Longitude: 103.8341600069, City: api.CITY_LAN_ZHOU, CountryCode: api.COUNTRY_CODE_CN}, "cn-sxty1": {Latitude: 37.8705857132, Longitude: 112.5506634865, City: api.CITY_TAI_YUAN, CountryCode: api.COUNTRY_CODE_CN}, "cn-sh1": {Latitude: 31.210344, Longitude: 121.455364, City: api.CITY_SHANG_HAI, CountryCode: api.COUNTRY_CODE_CN}, "cn-gz1": {Latitude: 26.6470035286, Longitude: 106.6302113880, City: api.CITY_GUI_YANG, CountryCode: api.COUNTRY_CODE_CN}, "cn-sdqd1": {Latitude: 36.067108, Longitude: 120.382607, City: api.CITY_QING_DAO, CountryCode: api.COUNTRY_CODE_CN}, "cn-tj1": {Latitude: 39.0850853357, Longitude: 117.1993482089, City: api.CITY_TIAN_JIN, CountryCode: api.COUNTRY_CODE_CN}, "cn-xjcj1": {Latitude: 43.8266013700, Longitude: 87.6168405804, City: api.CITY_WU_LU_MU_QI, CountryCode: api.COUNTRY_CODE_CN}, "cn-cq1": {Latitude: 29.431585, Longitude: 106.912254, City: api.CITY_CHONG_QING, CountryCode: api.COUNTRY_CODE_CN}, "cn-gxnn1": {Latitude: 22.8167372565, Longitude: 108.3669005333, City: api.CITY_NAN_NING, CountryCode: api.COUNTRY_CODE_CN}, "cn-hazz1": {Latitude: 34.7533581487, Longitude: 113.6313915479, City: api.CITY_ZHENG_ZHOU, CountryCode: api.COUNTRY_CODE_CN}, "cn-ynkm1": {Latitude: 24.8796595146, Longitude: 102.8332118852, City: api.CITY_KUN_MING, CountryCode: api.COUNTRY_CODE_CN}, "cn-xian1": {Latitude: 34.3412614674, Longitude: 108.9398165260, City: api.CITY_XI_AN, CountryCode: api.COUNTRY_CODE_CN}, "cn-hihk1": {Latitude: 20.0442268036, Longitude: 110.1998910288, City: api.CITY_HAI_KOU, CountryCode: api.COUNTRY_CODE_CN}, "cn-ahwh1": {Latitude: 31.3524675159, Longitude: 118.4331307290, City: api.CITY_WU_HU, CountryCode: api.COUNTRY_CODE_CN}, "cn-fz1": {Latitude: 26.0741979397, Longitude: 119.2964466153, City: api.CITY_FU_ZHOU, CountryCode: api.COUNTRY_CODE_CN}, "cn-nmhh1": {Latitude: 40.842358, Longitude: 111.749992, City: api.CITY_HU_HE_HAO_TE, CountryCode: api.COUNTRY_CODE_CN}, "cn-shanghai2": {Latitude: 31.210344, Longitude: 121.455364, City: api.CITY_SHANG_HAI, CountryCode: api.COUNTRY_CODE_CN}, "cn-snxy1": {Latitude: 34.3412614674, Longitude: 108.9398165260, City: api.CITY_XI_AN, CountryCode: api.COUNTRY_CODE_CN}, "cn-hbwh1": {Latitude: 30.5927599029, Longitude: 114.3052387810, City: api.CITY_WU_HAN, CountryCode: api.COUNTRY_CODE_CN}, "cn-hncs1": {Latitude: 28.2277765095, Longitude: 112.9388453666, City: api.CITY_CHANG_SHA, CountryCode: api.COUNTRY_CODE_CN}, "cn-guangzhou2": {Latitude: 23.12911, Longitude: 113.264385, City: api.CITY_GUANG_ZHOU, CountryCode: api.COUNTRY_CODE_CN}, "cn-guizhou2": {Latitude: 26.6470035286, Longitude: 106.6302113880, City: api.CITY_GUI_YANG, CountryCode: api.COUNTRY_CODE_CN}, "cn-jssz1": {Latitude: 31.2983479333, Longitude: 120.5831894861, City: api.CITY_SU_ZHOU, CountryCode: api.COUNTRY_CODE_CN}, "cn-sccd1": {Latitude: 30.572815, Longitude: 104.066803, City: api.CITY_CHENG_DU, CountryCode: api.COUNTRY_CODE_CN}, "cn-guangzhou3": {Latitude: 23.12911, Longitude: 113.264385, City: api.CITY_GUANG_ZHOU, CountryCode: api.COUNTRY_CODE_CN}, "cn-shanghai3": {Latitude: 31.210344, Longitude: 121.455364, City: api.CITY_SHANG_HAI, CountryCode: api.COUNTRY_CODE_CN}, "cn-neimeng4": {Latitude: 40.842358, Longitude: 111.749992, City: api.CITY_HU_HE_HAO_TE, CountryCode: api.COUNTRY_CODE_CN}, "cn-beijing3": {Latitude: 39.904202, Longitude: 116.407394, City: api.CITY_BEI_JING, CountryCode: api.COUNTRY_CODE_CN}, "cn-baoding1": {Latitude: 38.8739745619, Longitude: 115.4646082830, City: api.CITY_BAO_DING, CountryCode: api.COUNTRY_CODE_CN}, "cn-nj2": {Latitude: 32.0584065670, Longitude: 118.7964897811, City: api.CITY_NAN_JING, CountryCode: api.COUNTRY_CODE_CN}, "cn-gdgz1": {Latitude: 23.12911, Longitude: 113.264385, City: api.CITY_GUANG_ZHOU, CountryCode: api.COUNTRY_CODE_CN}, "cn-bj1": {Latitude: 39.904202, Longitude: 116.407394, City: api.CITY_BEI_JING, CountryCode: api.COUNTRY_CODE_CN}, "cn-bj4": {Latitude: 39.904202, Longitude: 116.407394, City: api.CITY_BEI_JING, CountryCode: api.COUNTRY_CODE_CN}, "cn-neimeng5": {Latitude: 40.842358, Longitude: 111.749992, City: api.CITY_HU_HE_HAO_TE, CountryCode: api.COUNTRY_CODE_CN}, "cn-shanghai5": {Latitude: 31.210344, Longitude: 121.455364, City: api.CITY_SHANG_HAI, CountryCode: api.COUNTRY_CODE_CN}, "cn-sh6": {Latitude: 31.210344, Longitude: 121.455364, City: api.CITY_SHANG_HAI, CountryCode: api.COUNTRY_CODE_CN}, "cn-gdfs2": {Latitude: 23.0218629843, Longitude: 113.1219225896, City: api.CITY_FO_SHAN, CountryCode: api.COUNTRY_CODE_CN}, }
var StorageTypes = []string{ api.STORAGE_CTYUN_SAS, api.STORAGE_CTYUN_SATA, api.STORAGE_CTYUN_SSD, }
Functions ¶
func GetBucketName ¶
Types ¶
type Attachment ¶
type CtyunClientConfig ¶
type CtyunClientConfig struct {
// contains filtered or unexported fields
}
func NewSCtyunClientConfig ¶
func NewSCtyunClientConfig(accessKey, accessSecret string, options *cloudprovider.SCtyunExtraOptions) *CtyunClientConfig
func (*CtyunClientConfig) CloudproviderConfig ¶
func (cfg *CtyunClientConfig) CloudproviderConfig(cpcfg cloudprovider.ProviderConfig) *CtyunClientConfig
func (*CtyunClientConfig) Debug ¶
func (cfg *CtyunClientConfig) Debug(debug bool) *CtyunClientConfig
func (*CtyunClientConfig) ProjectId ¶
func (cfg *CtyunClientConfig) ProjectId(projectId string) *CtyunClientConfig
type DiskDetails ¶
type DiskDetails struct { ID string `json:"id"` ResEbsID string `json:"resEbsId"` Size int64 `json:"size"` Name string `json:"name"` RegionID string `json:"regionId"` AccountID string `json:"accountId"` UserID string `json:"userId"` HostID string `json:"hostId"` OrderID string `json:"orderId"` Status int64 `json:"status"` Type string `json:"type"` VolumeStatus int64 `json:"volumeStatus"` CreateDate int64 `json:"createDate"` DueDate int64 `json:"dueDate"` ZoneID string `json:"zoneId"` ZoneName string `json:"zoneName"` IsSysVolume int64 `json:"isSysVolume"` IsPackaged int64 `json:"isPackaged"` WorkOrderResourceID string `json:"workOrderResourceId"` IsFreeze int64 `json:"isFreeze"` }
type InstanceDetails ¶
type InstanceDetails struct { HostID string `json:"hostId"` Name string `json:"name"` Status string `json:"status"` PrivateIPS []PrivateIP `json:"privateIps"` PublicIPS []PublicIP `json:"publicIps"` Volumes []Volume `json:"volumes"` Created string `json:"created"` FlavorObj FlavorObj `json:"flavorObj"` }
type PublicipInfo ¶
type ResourceConfigMap ¶
type ResourceConfigMap struct { AvailabilityZone string `json:"availability_zone"` Value string `json:"value"` Number string `json:"number"` IsSystemVolume bool `json:"isSystemVolume"` VolumeType string `json:"volumeType"` Size int64 `json:"size"` ZoneID string `json:"zoneId"` RegionID string `json:"regionId"` Version string `json:"version"` CycleCnt int64 `json:"cycleCnt"` CycleType int64 `json:"cycleType"` ResEbsID string `json:"resEbsId"` ActualResourceID string `json:"actualResourceId"` SecurityGroups []SecurityGroupID `json:"security_groups"` }
type SBandwidth ¶
type SBandwidth struct { PublicipInfo []PublicipInfo `json:"publicip_info"` EnterpriseProjectID string `json:"enterprise_project_id"` Name string `json:"name"` ID string `json:"id"` Size int64 `json:"size"` TenantID string `json:"tenant_id"` ChargeMode string `json:"charge_mode"` BandwidthType string `json:"bandwidth_type"` }
type SCrmUser ¶
type SCrmUser struct { LoginName string `json:"loginName"` LoginEmail string `json:"loginEmail"` RootUserid string `json:"rootUserid"` CreateDate int64 `json:"createDate"` AccountType int64 `json:"accountType"` Status int64 `json:"status"` Province string `json:"province"` City string `json:"city"` Mobilephone string `json:"mobilephone"` Postpaid int64 `json:"postpaid"` Channel int64 `json:"channel"` AuditStatus string `json:"auditStatus"` AuditMsg string `json:"auditMsg"` }
type SCtyunClient ¶
type SCtyunClient struct { *CtyunClientConfig // contains filtered or unexported fields }
func NewSCtyunClient ¶
func NewSCtyunClient(cfg *CtyunClientConfig) (*SCtyunClient, error)
func (*SCtyunClient) DoGet ¶
func (client *SCtyunClient) DoGet(apiName string, queries map[string]string) (jsonutils.JSONObject, error)
func (*SCtyunClient) DoPost ¶
func (client *SCtyunClient) DoPost(apiName string, params map[string]jsonutils.JSONObject) (jsonutils.JSONObject, error)
func (*SCtyunClient) FetchProjects ¶
func (self *SCtyunClient) FetchProjects() ([]SProject, error)
func (*SCtyunClient) GetAccessEnv ¶
func (self *SCtyunClient) GetAccessEnv() string
func (*SCtyunClient) GetAccountId ¶
func (client *SCtyunClient) GetAccountId() string
func (*SCtyunClient) GetCapabilities ¶
func (self *SCtyunClient) GetCapabilities() []string
func (*SCtyunClient) GetCloudRegionExternalIdPrefix ¶
func (self *SCtyunClient) GetCloudRegionExternalIdPrefix() string
func (*SCtyunClient) GetIProjects ¶
func (self *SCtyunClient) GetIProjects() ([]cloudprovider.ICloudProject, error)
func (*SCtyunClient) GetIRegionById ¶
func (self *SCtyunClient) GetIRegionById(id string) (cloudprovider.ICloudRegion, error)
func (*SCtyunClient) GetIRegions ¶
func (self *SCtyunClient) GetIRegions() []cloudprovider.ICloudRegion
func (*SCtyunClient) GetRegion ¶
func (self *SCtyunClient) GetRegion(regionId string) *SRegion
func (*SCtyunClient) GetRegions ¶
func (self *SCtyunClient) GetRegions() []SRegion
func (*SCtyunClient) GetSubAccounts ¶
func (self *SCtyunClient) GetSubAccounts() ([]cloudprovider.SSubAccount, error)
type SDisk ¶
type SDisk struct { multicloud.SDisk CtyunTags multicloud.SBillingBase ID string `json:"id"` Status string `json:"status"` Name string `json:"name"` CreatedAt int64 `json:"created_at"` UpdatedAt string `json:"updated_at"` Multiattach bool `json:"multiattach"` ReplicationStatus string `json:"replication_status"` SizeGB int64 `json:"size"` Metadata Metadata `json:"metadata"` VolumeType string `json:"volume_type"` UserID string `json:"user_id"` Encrypted bool `json:"encrypted"` Bootable string `json:"bootable"` AvailabilityZone string `json:"availability_zone"` Attachments []Attachment `json:"attachments"` MasterOrderID string `json:"masterOrderId"` WorkOrderResourceID string `json:"workOrderResourceId"` ExpireTime int64 `json:"expireTime"` IsFreeze int64 `json:"isFreeze"` // contains filtered or unexported fields }
http://ctyun-api-url/apiproxy/v3/ondemand/queryVolumes
func (*SDisk) CreateISnapshot ¶
func (self *SDisk) CreateISnapshot(ctx context.Context, name string, desc string) (cloudprovider.ICloudSnapshot, error)
func (*SDisk) GetAccessPath ¶
func (*SDisk) GetBillingType ¶
func (*SDisk) GetCacheMode ¶
func (*SDisk) GetCreatedAt ¶
func (*SDisk) GetDiskDetails ¶
func (self *SDisk) GetDiskDetails() (*DiskDetails, error)
func (*SDisk) GetDiskFormat ¶
func (*SDisk) GetDiskSizeMB ¶
func (*SDisk) GetDiskType ¶
func (*SDisk) GetExpiredAt ¶
func (*SDisk) GetExtSnapshotPolicyIds ¶
POST http://ctyun-api-url/apiproxy/v3/ondemand/updateDiskBackupPolicy
func (*SDisk) GetFsFormat ¶
func (*SDisk) GetGlobalId ¶
func (*SDisk) GetISnapshot ¶
func (self *SDisk) GetISnapshot(idStr string) (cloudprovider.ICloudSnapshot, error)
func (*SDisk) GetISnapshots ¶
func (self *SDisk) GetISnapshots() ([]cloudprovider.ICloudSnapshot, error)
no snapshot api opened
func (*SDisk) GetIStorage ¶
func (self *SDisk) GetIStorage() (cloudprovider.ICloudStorage, error)
func (*SDisk) GetIStorageId ¶
func (*SDisk) GetIsAutoDelete ¶
func (*SDisk) GetIsNonPersistent ¶
func (*SDisk) GetMountpoint ¶
func (*SDisk) GetProjectId ¶
func (*SDisk) GetSysTags ¶
func (*SDisk) GetTemplateId ¶
func (*SDisk) IsEmulated ¶
type SDiskBackup ¶
type SDiskBackup struct { multicloud.SResourceBase CtyunTags Status string `json:"status"` Description string `json:"description"` AvailabilityZone string `json:"availability_zone"` VolumeID string `json:"volume_id"` FailReason string `json:"fail_reason"` ID string `json:"id"` Size int32 `json:"size"` Container string `json:"container"` Name string `json:"name"` CreatedAt string `json:"created_at"` // contains filtered or unexported fields }
func (*SDiskBackup) Delete ¶
func (self *SDiskBackup) Delete() error
func (*SDiskBackup) GetDiskId ¶
func (self *SDiskBackup) GetDiskId() string
func (*SDiskBackup) GetDiskType ¶
func (self *SDiskBackup) GetDiskType() string
func (*SDiskBackup) GetGlobalId ¶
func (self *SDiskBackup) GetGlobalId() string
func (*SDiskBackup) GetId ¶
func (self *SDiskBackup) GetId() string
func (*SDiskBackup) GetName ¶
func (self *SDiskBackup) GetName() string
func (*SDiskBackup) GetProjectId ¶
func (self *SDiskBackup) GetProjectId() string
func (*SDiskBackup) GetSizeMb ¶
func (self *SDiskBackup) GetSizeMb() int32
func (*SDiskBackup) GetStatus ¶
func (self *SDiskBackup) GetStatus() string
func (*SDiskBackup) IsEmulated ¶
func (self *SDiskBackup) IsEmulated() bool
func (*SDiskBackup) Refresh ¶
func (self *SDiskBackup) Refresh() error
type SDiskBacupPolicy ¶
type SDiskBacupPolicy struct { multicloud.SResourceBase CtyunTags PolicyResourceCount int64 `json:"policy_resource_count"` BackupPolicyName string `json:"backup_policy_name"` ScheduledPolicy ScheduledPolicy `json:"scheduled_policy"` BackupPolicyID string `json:"backup_policy_id"` // contains filtered or unexported fields }
func (*SDiskBacupPolicy) GetGlobalId ¶
func (self *SDiskBacupPolicy) GetGlobalId() string
func (*SDiskBacupPolicy) GetId ¶
func (self *SDiskBacupPolicy) GetId() string
func (*SDiskBacupPolicy) GetName ¶
func (self *SDiskBacupPolicy) GetName() string
func (*SDiskBacupPolicy) GetProjectId ¶
func (self *SDiskBacupPolicy) GetProjectId() string
func (*SDiskBacupPolicy) GetRepeatWeekdays ¶
func (self *SDiskBacupPolicy) GetRepeatWeekdays() ([]int, error)
func (*SDiskBacupPolicy) GetRetentionDays ¶
func (self *SDiskBacupPolicy) GetRetentionDays() int
func (*SDiskBacupPolicy) GetStatus ¶
func (self *SDiskBacupPolicy) GetStatus() string
func (*SDiskBacupPolicy) GetTimePoints ¶
func (self *SDiskBacupPolicy) GetTimePoints() ([]int, error)
func (*SDiskBacupPolicy) IsActivated ¶
func (self *SDiskBacupPolicy) IsActivated() bool
func (*SDiskBacupPolicy) IsEmulated ¶
func (self *SDiskBacupPolicy) IsEmulated() bool
func (*SDiskBacupPolicy) Refresh ¶
func (self *SDiskBacupPolicy) Refresh() error
type SDiskDetails ¶
type SDiskDetails struct { HostID string `json:"hostId"` Name string `json:"name"` Status string `json:"status"` PrivateIPS []PrivateIP `json:"privateIps"` PublicIPS []PublicIP `json:"publicIps"` Volumes []Volume `json:"volumes"` Created string `json:"created"` FlavorObj FlavorObj `json:"flavorObj"` }
type SEip ¶
type SEip struct { multicloud.SEipBase CtyunTags IPVersion int64 `json:"ip_version"` Type string `json:"type"` PrivateIPAddress string `json:"private_ip_address"` EnterpriseProjectID string `json:"enterprise_project_id"` Status string `json:"status"` PublicIPAddress string `json:"public_ip_address"` ID string `json:"id"` TenantID string `json:"tenant_id"` Profile Profile `json:"profile"` BandwidthName string `json:"bandwidth_name"` BandwidthID string `json:"bandwidth_id"` PortID string `json:"port_id"` BandwidthSize int `json:"bandwidth_size"` CreateTime int64 `json:"create_time"` MasterOrderID string `json:"masterOrderId"` WorkOrderResourceID string `json:"workOrderResourceId"` ExpireTime int64 `json:"expireTime"` IsFreeze int64 `json:"isFreeze"` // contains filtered or unexported fields }
func (*SEip) Associate ¶
func (self *SEip) Associate(conf *cloudprovider.AssociateConfig) error
func (*SEip) ChangeBandwidth ¶
func (*SEip) Dissociate ¶
func (*SEip) GetAssociationExternalId ¶
eip查询接口未返回 绑定的实例ID/网卡port id。导致不能正常找出关联的主机
func (*SEip) GetAssociationType ¶
func (*SEip) GetBandwidth ¶
func (*SEip) GetBillingType ¶
func (*SEip) GetCreatedAt ¶
func (*SEip) GetExpiredAt ¶
func (*SEip) GetGlobalId ¶
func (*SEip) GetINetworkId ¶
func (*SEip) GetInternetChargeType ¶
func (*SEip) GetProjectId ¶
func (*SEip) IsEmulated ¶
type SHost ¶
type SHost struct { multicloud.SHostBase // contains filtered or unexported fields }
func (*SHost) CreateVM ¶
func (self *SHost) CreateVM(desc *cloudprovider.SManagedVMCreateConfig) (cloudprovider.ICloudVM, error)
func (*SHost) GetAccessIp ¶
func (*SHost) GetAccessMac ¶
func (*SHost) GetCpuCount ¶
func (*SHost) GetCpuDesc ¶
func (*SHost) GetEnabled ¶
func (*SHost) GetGlobalId ¶
func (*SHost) GetHostStatus ¶
func (*SHost) GetHostType ¶
func (*SHost) GetIHostNics ¶
func (self *SHost) GetIHostNics() ([]cloudprovider.ICloudHostNetInterface, error)
func (*SHost) GetIStorageById ¶
func (self *SHost) GetIStorageById(id string) (cloudprovider.ICloudStorage, error)
func (*SHost) GetIStorages ¶
func (self *SHost) GetIStorages() ([]cloudprovider.ICloudStorage, error)
func (*SHost) GetIVMById ¶
func (self *SHost) GetIVMById(id string) (cloudprovider.ICloudVM, error)
http://ctyun-api-url/apiproxy/v3/ondemand/queryVMDetail
http://ctyun-api-url/apiproxy/v3/queryVMDetail
func (*SHost) GetIWires ¶
func (self *SHost) GetIWires() ([]cloudprovider.ICloudWire, error)
func (*SHost) GetIsMaintenance ¶
func (*SHost) GetMemSizeMB ¶
func (*SHost) GetNodeCount ¶
func (*SHost) GetStorageSizeMB ¶
func (*SHost) GetStorageType ¶
func (*SHost) GetSysInfo ¶
func (self *SHost) GetSysInfo() jsonutils.JSONObject
func (*SHost) GetVersion ¶
func (*SHost) IsEmulated ¶
type SImage ¶
type SImage struct { multicloud.SImageBase CtyunTags ID string `json:"id"` OSType string `json:"osType"` Platform string `json:"platform"` Name string `json:"name"` OSBit int64 `json:"osBit"` OSVersion string `json:"osVersion"` MinRAM int64 `json:"minRam"` MinDisk int64 `json:"minDisk"` ImageType string `json:"imageType"` Virtual bool `json:"virtual"` // contains filtered or unexported fields }
http://ctyun-api-url/apiproxy/v3/order/getImages
func (*SImage) GetBios ¶
func (self *SImage) GetBios() cloudprovider.TBiosType
func (*SImage) GetCreateTime ¶
func (*SImage) GetCreatedAt ¶
func (*SImage) GetFullOsName ¶
func (*SImage) GetGlobalId ¶
func (*SImage) GetIStoragecache ¶
func (self *SImage) GetIStoragecache() cloudprovider.ICloudStoragecache
func (*SImage) GetImageFormat ¶
func (*SImage) GetImageStatus ¶
func (*SImage) GetImageType ¶
func (self *SImage) GetImageType() cloudprovider.TImageType
func (*SImage) GetMinOsDiskSizeGb ¶
func (*SImage) GetMinRamSizeMb ¶
func (*SImage) GetOsType ¶
func (self *SImage) GetOsType() cloudprovider.TOsType
func (*SImage) GetOsVersion ¶
func (*SImage) GetSizeByte ¶
func (*SImage) IsEmulated ¶
type SInstance ¶
type SInstance struct { multicloud.SInstanceBase CtyunTags multicloud.SBillingBase HostID string `json:"hostId"` ID string `json:"id"` Name string `json:"name"` Status string `json:"status"` TenantID string `json:"tenant_id"` Metadata Metadata `json:"metadata"` Image Image `json:"image"` Flavor FlavorObj `json:"flavor"` Addresses map[string][]Address `json:"addresses"` UserID string `json:"user_id"` Created time.Time `json:"created"` DueDate *time.Time `json:"dueDate"` SecurityGroups []SecurityGroup `json:"security_groups"` OSEXTAZAvailabilityZone string `json:"OS-EXT-AZ:availability_zone"` OSExtendedVolumesVolumesAttached []Volume `json:"os-extended-volumes:volumes_attached"` MasterOrderId string `json:"masterOrderId"` // contains filtered or unexported fields }
func (*SInstance) AssignSecurityGroup ¶
func (*SInstance) AttachDisk ¶
func (*SInstance) ChangeConfig ¶
func (self *SInstance) ChangeConfig(ctx context.Context, config *cloudprovider.SManagedVMChangeConfig) error
func (*SInstance) DetachDisk ¶
func (*SInstance) GetBillingType ¶
func (*SInstance) GetBios ¶
func (self *SInstance) GetBios() cloudprovider.TBiosType
func (*SInstance) GetBootOrder ¶
func (*SInstance) GetCreatedAt ¶
func (*SInstance) GetDetails ¶
func (self *SInstance) GetDetails() (*InstanceDetails, error)
func (*SInstance) GetExpiredAt ¶
func (*SInstance) GetFullOsName ¶
func (*SInstance) GetGlobalId ¶
func (*SInstance) GetHostname ¶
func (*SInstance) GetHypervisor ¶
func (*SInstance) GetIDisks ¶
func (self *SInstance) GetIDisks() ([]cloudprovider.ICloudDisk, error)
func (*SInstance) GetIHost ¶
func (self *SInstance) GetIHost() cloudprovider.ICloudHost
func (*SInstance) GetInstanceType ¶
func (*SInstance) GetMachine ¶
func (*SInstance) GetOsType ¶
func (self *SInstance) GetOsType() cloudprovider.TOsType
func (*SInstance) GetOsVersion ¶
func (*SInstance) GetProjectId ¶
func (*SInstance) GetSecurityGroupIds ¶
func (*SInstance) GetVNCInfo ¶
func (self *SInstance) GetVNCInfo(input *cloudprovider.ServerVncInput) (*cloudprovider.ServerVncOutput, error)
func (*SInstance) GetVcpuCount ¶
func (*SInstance) GetVmemSizeMB ¶
func (*SInstance) IsEmulated ¶
func (*SInstance) NextDeviceName ¶
func (*SInstance) RebuildRoot ¶
func (self *SInstance) RebuildRoot(ctx context.Context, config *cloudprovider.SManagedVMRebuildRootConfig) (string, error)
func (*SInstance) SetSecurityGroups ¶
func (*SInstance) StopVM ¶
func (self *SInstance) StopVM(ctx context.Context, opts *cloudprovider.ServerStopOptions) error
func (*SInstance) UpdateUserData ¶
type SInstanceNic ¶
type SInstanceNic struct { FixedIPS []FixedIP `json:"fixed_ips"` PortState string `json:"port_state"` PortID string `json:"port_id"` MACAddr string `json:"mac_addr"` NetID string `json:"net_id"` cloudprovider.DummyICloudNic // contains filtered or unexported fields }
func (*SInstanceNic) GetDriver ¶
func (self *SInstanceNic) GetDriver() string
func (*SInstanceNic) GetINetworkId ¶
func (self *SInstanceNic) GetINetworkId() string
func (*SInstanceNic) GetIP ¶
func (self *SInstanceNic) GetIP() string
func (*SInstanceNic) GetId ¶
func (self *SInstanceNic) GetId() string
func (*SInstanceNic) GetMAC ¶
func (self *SInstanceNic) GetMAC() string
func (*SInstanceNic) InClassicNetwork ¶
func (self *SInstanceNic) InClassicNetwork() bool
type SKeypair ¶
type SKeypair struct { Fingerprint string `json:"fingerprint"` Name string `json:"name"` PublicKey string `json:"public_key"` }
GET http://ctyun-api-url/apiproxy/v3/querySSH POST http://ctyun-api-url/apiproxy/v3/deleteSSH
type SNetwork ¶
type SNetwork struct { multicloud.SResourceBase CtyunTags CIDR string `json:"cidr"` FirstDcn string `json:"firstDcn"` Gateway string `json:"gateway"` Name string `json:"name"` NeutronSubnetID string `json:"neutronSubnetId"` RegionID string `json:"regionId"` ResVLANID string `json:"resVlanId"` SecondDcn string `json:"secondDcn"` VLANStatus string `json:"vlanStatus"` VpcID string `json:"vpcId"` ZoneID string `json:"zoneId"` ZoneName string `json:"zoneName"` // contains filtered or unexported fields }
func (*SNetwork) GetAllocTimeoutSeconds ¶
func (*SNetwork) GetGateway ¶
func (*SNetwork) GetGlobalId ¶
func (*SNetwork) GetIWire ¶
func (self *SNetwork) GetIWire() cloudprovider.ICloudWire
func (*SNetwork) GetIpStart ¶
func (*SNetwork) GetIsPublic ¶
func (*SNetwork) GetProjectId ¶
func (*SNetwork) GetPublicScope ¶
func (self *SNetwork) GetPublicScope() rbacutils.TRbacScope
func (*SNetwork) GetServerType ¶
func (*SNetwork) IsEmulated ¶
type SOrder ¶
type SOrder struct { OrderItemID string `json:"orderItemId"` InstanceID string `json:"instanceId"` AccountID string `json:"accountId"` UserID string `json:"userId"` InnerOrderID string `json:"innerOrderId"` InnerOrderItemID string `json:"innerOrderItemId"` ProductID string `json:"productId"` MasterOrderID string `json:"masterOrderId"` OrderID string `json:"orderId"` MasterResourceID string `json:"masterResourceId"` ResourceID string `json:"resourceId"` ServiceTag string `json:"serviceTag"` ResourceType string `json:"resourceType"` ResourceInfo string `json:"resourceInfo"` StartDate int64 `json:"startDate"` ExpireDate int64 `json:"expireDate"` CreateDate int64 `json:"createDate"` UpdateDate int64 `json:"updateDate"` Status int64 `json:"status"` WorkOrderID string `json:"workOrderId"` WorkOrderItemID string `json:"workOrderItemId"` SalesEntryID string `json:"salesEntryId"` OrderStatus int64 `json:"orderStatus"` ToOndemand string `json:"toOndemand"` ItemValue string `json:"itemValue"` ChargingStatus int64 `json:"chargingStatus"` ChargingDate int64 `json:"chargingDate"` ResourceConfig string `json:"resourceConfig"` AutoToOnDemand bool `json:"autoToOnDemand"` BuildingChannel int64 `json:"buildingChannel"` IsPlatformSpecific bool `json:"isPlatformSpecific"` BillingOwner int64 `json:"billingOwner"` IsPackage bool `json:"isPackage"` CanRelease bool `json:"canRelease"` IsChargeOff bool `json:"isChargeOff"` IsPublicTest int64 `json:"isPublicTest"` Master bool `json:"master"` ResourceConfigMap ResourceConfigMap `json:"resourceConfigMap"` }
type SProject ¶
type SProject struct { Enabled bool `json:"enabled"` Name string `json:"name"` Description string `json:"description"` ID string `json:"id"` }
GET http://ctyun-api-url/apiproxy/v3/ondemand/queryProjectIds
func (*SProject) GetHealthStatus ¶
func (*SProject) GetRegionID ¶
type SRegion ¶
type SRegion struct { cloudprovider.SFakeOnPremiseRegion multicloud.SRegion multicloud.SNoObjectStorageRegion RegionName string Description string `json:"description"` ID string `json:"id"` ParentRegionID string `json:"parent_region_id"` Type string `json:"type"` // contains filtered or unexported fields }
func (*SRegion) AddSecurityGroupRules ¶
func (self *SRegion) AddSecurityGroupRules(secGrpId string, rule cloudprovider.SecurityRule) error
func (*SRegion) ApplySnapshotPolicyToDisks ¶
func (*SRegion) AssignSecurityGroup ¶
POST http://ctyun-api-url/apiproxy/v3/addSecurityGroup 绑定安全组
func (*SRegion) AssociateEip ¶
这里networkCardId 实际指的是port id
func (*SRegion) AttachDisk ¶
func (*SRegion) BindingDiskBackupPolicy ¶
func (*SRegion) CancelSnapshotPolicyToDisks ¶
func (*SRegion) ChangeBandwidthEip ¶
func (*SRegion) ChangeVMConfig ¶
func (*SRegion) CreateDisk ¶
func (*SRegion) CreateDiskBackup ¶
func (*SRegion) CreateDiskBackupPolicy ¶
func (*SRegion) CreateEIP ¶
func (self *SRegion) CreateEIP(eip *cloudprovider.SEip) (cloudprovider.ICloudEIP, error)
func (*SRegion) CreateISecurityGroup ¶
func (self *SRegion) CreateISecurityGroup(conf *cloudprovider.SecurityGroupCreateInput) (cloudprovider.ICloudSecurityGroup, error)
func (*SRegion) CreateIVpc ¶
func (self *SRegion) CreateIVpc(opts *cloudprovider.VpcCreateOptions) (cloudprovider.ICloudVpc, error)
func (*SRegion) CreateInstance ¶
func (self *SRegion) CreateInstance(zoneId, name, imageId, osType, flavorRef, vpcid, subnetId, secGroupId, adminPass, volumetype string, volumeSize int, dataDisks []cloudprovider.SDiskInfo) (string, error)
创建主机接口目前没有绑定密钥的参数选项,不支持绑定密码。 但是重装系统接口支持绑定密钥
func (*SRegion) CreateNetwork ¶
func (*SRegion) CreateSecurityGroup ¶
func (self *SRegion) CreateSecurityGroup(vpcId, name string) (*SSecurityGroup, error)
func (*SRegion) CreateSecurityGroupRule ¶
func (*SRegion) CreateSnapshotPolicy ¶
func (self *SRegion) CreateSnapshotPolicy(*cloudprovider.SnapshotPolicyInput) (string, error)
func (*SRegion) DeleteDiskBackup ¶
func (*SRegion) DeleteNetwork ¶
func (*SRegion) DeleteSecurityGroup ¶
func (*SRegion) DeleteSecurityGroupRule ¶
func (*SRegion) DeleteSnapshotPolicy ¶
func (*SRegion) DetachDisk ¶
func (*SRegion) DissociateEip ¶
func (*SRegion) FetchProjects ¶
func (*SRegion) GetCapabilities ¶
func (*SRegion) GetClient ¶
func (self *SRegion) GetClient() *SCtyunClient
func (*SRegion) GetCrmUser ¶
func (*SRegion) GetDiskBackup ¶
func (self *SRegion) GetDiskBackup(diskId string, backupId string) (*SDiskBackup, error)
func (*SRegion) GetDiskBackupPolices ¶
func (self *SRegion) GetDiskBackupPolices() ([]SDiskBacupPolicy, error)
func (*SRegion) GetDiskBackupPolicy ¶
func (self *SRegion) GetDiskBackupPolicy(policyId string) (*SDiskBacupPolicy, error)
func (*SRegion) GetDiskBackups ¶
func (self *SRegion) GetDiskBackups(diskId string) ([]SDiskBackup, error)
func (*SRegion) GetDiskDetailByDiskId ¶
func (self *SRegion) GetDiskDetailByDiskId(diskId string) (*DiskDetails, error)
func (*SRegion) GetGeographicInfo ¶
func (self *SRegion) GetGeographicInfo() cloudprovider.SGeographicInfo
func (*SRegion) GetGlobalId ¶
func (*SRegion) GetI18n ¶
func (self *SRegion) GetI18n() cloudprovider.SModelI18nTable
func (*SRegion) GetIDiskById ¶
func (self *SRegion) GetIDiskById(id string) (cloudprovider.ICloudDisk, error)
func (*SRegion) GetIEipById ¶
func (self *SRegion) GetIEipById(id string) (cloudprovider.ICloudEIP, error)
func (*SRegion) GetIHostById ¶
func (self *SRegion) GetIHostById(id string) (cloudprovider.ICloudHost, error)
func (*SRegion) GetIHosts ¶
func (self *SRegion) GetIHosts() ([]cloudprovider.ICloudHost, error)
func (*SRegion) GetISecurityGroupById ¶
func (self *SRegion) GetISecurityGroupById(secgroupId string) (cloudprovider.ICloudSecurityGroup, error)
func (*SRegion) GetISecurityGroupByName ¶
func (self *SRegion) GetISecurityGroupByName(opts *cloudprovider.SecurityGroupFilterOptions) (cloudprovider.ICloudSecurityGroup, error)
func (*SRegion) GetISnapshotById ¶
func (self *SRegion) GetISnapshotById(snapshotId string) (cloudprovider.ICloudSnapshot, error)
func (*SRegion) GetISnapshotPolicies ¶
func (self *SRegion) GetISnapshotPolicies() ([]cloudprovider.ICloudSnapshotPolicy, error)
func (*SRegion) GetISnapshotPolicyById ¶
func (self *SRegion) GetISnapshotPolicyById(snapshotPolicyId string) (cloudprovider.ICloudSnapshotPolicy, error)
func (*SRegion) GetISnapshots ¶
func (self *SRegion) GetISnapshots() ([]cloudprovider.ICloudSnapshot, error)
func (*SRegion) GetIStorageById ¶
func (self *SRegion) GetIStorageById(id string) (cloudprovider.ICloudStorage, error)
func (*SRegion) GetIStoragecacheById ¶
func (self *SRegion) GetIStoragecacheById(id string) (cloudprovider.ICloudStoragecache, error)
func (*SRegion) GetIStoragecaches ¶
func (self *SRegion) GetIStoragecaches() ([]cloudprovider.ICloudStoragecache, error)
func (*SRegion) GetIStorages ¶
func (self *SRegion) GetIStorages() ([]cloudprovider.ICloudStorage, error)
func (*SRegion) GetIVMById ¶
func (self *SRegion) GetIVMById(id string) (cloudprovider.ICloudVM, error)
func (*SRegion) GetIVpcById ¶
func (self *SRegion) GetIVpcById(id string) (cloudprovider.ICloudVpc, error)
func (*SRegion) GetIVpcs ¶
func (self *SRegion) GetIVpcs() ([]cloudprovider.ICloudVpc, error)
http://ctyun-api-url/apiproxy/v3/getVpcs http://ctyun-api-url/apiproxy/v3/getVpcs
func (*SRegion) GetIZoneById ¶
func (self *SRegion) GetIZoneById(id string) (cloudprovider.ICloudZone, error)
func (*SRegion) GetIZones ¶
func (self *SRegion) GetIZones() ([]cloudprovider.ICloudZone, error)
func (*SRegion) GetInstanceFlavors ¶
func (*SRegion) GetInstanceVNCUrl ¶
func (*SRegion) GetInstances ¶
func (*SRegion) GetJob ¶
func (self *SRegion) GetJob(jobId string) (jsonutils.JSONObject, error)
vm & nic job
func (*SRegion) GetKeypairs ¶
func (*SRegion) GetProvider ¶
func (*SRegion) GetSecurityGroupDetails ¶
func (self *SRegion) GetSecurityGroupDetails(groupId string) (*SSecurityGroup, error)
func (*SRegion) GetSecurityGroupRules ¶
func (self *SRegion) GetSecurityGroupRules(secgroupId string) ([]SSecurityGroupRule, error)
func (*SRegion) GetSecurityGroups ¶
func (self *SRegion) GetSecurityGroups(vpcId string) ([]SSecurityGroup, error)
func (*SRegion) GetVMDetails ¶
func (self *SRegion) GetVMDetails(vmId string) (*InstanceDetails, error)
func (*SRegion) GetVbsJob ¶
func (self *SRegion) GetVbsJob(jobId string) (jsonutils.JSONObject, error)
查询云硬盘备份JOB状态信息
func (*SRegion) GetVolumeJob ¶
func (self *SRegion) GetVolumeJob(jobId string) (jsonutils.JSONObject, error)
查询云硬盘JOB状态信息
func (*SRegion) ImportKeypair ¶
func (*SRegion) IsEmulated ¶
func (*SRegion) RenewVM ¶
POST http://ctyun-api-url/apiproxy/v3/order/placeRenewOrder 续订
func (*SRegion) ResetVMPassword ¶
func (*SRegion) ResizeDisk ¶
func (*SRegion) RestoreDisk ¶
func (*SRegion) SwitchVMOs ¶
func (*SRegion) UnBindDiskBackupPolicy ¶
func (*SRegion) UnsignSecurityGroup ¶
POST http://ctyun-api-url/apiproxy/v3/removeSecurityGroup 解绑安全组
func (*SRegion) UpdateSnapshotPolicy ¶
func (self *SRegion) UpdateSnapshotPolicy(*cloudprovider.SnapshotPolicyInput, string) error
type SSecurityGroup ¶
type SSecurityGroup struct { multicloud.SSecurityGroup CtyunTags ResSecurityGroupID string `json:"resSecurityGroupId"` Name string `json:"name"` AccountID string `json:"accountId"` UserID string `json:"userId"` RegionID string `json:"regionId"` ZoneID string `json:"zoneId"` VpcID string `json:"vpcId"` CreateDate int64 `json:"createDate"` Status int64 `json:"status"` // contains filtered or unexported fields }
func (*SSecurityGroup) Delete ¶
func (self *SSecurityGroup) Delete() error
func (*SSecurityGroup) GetDescription ¶
func (self *SSecurityGroup) GetDescription() string
func (*SSecurityGroup) GetGlobalId ¶
func (self *SSecurityGroup) GetGlobalId() string
func (*SSecurityGroup) GetId ¶
func (self *SSecurityGroup) GetId() string
func (*SSecurityGroup) GetName ¶
func (self *SSecurityGroup) GetName() string
func (*SSecurityGroup) GetRules ¶
func (self *SSecurityGroup) GetRules() ([]cloudprovider.SecurityRule, error)
func (*SSecurityGroup) GetSecurityRule ¶
func (self *SSecurityGroup) GetSecurityRule(remoteRule SSecurityGroupRule) (cloudprovider.SecurityRule, error)
func (*SSecurityGroup) GetStatus ¶
func (self *SSecurityGroup) GetStatus() string
func (*SSecurityGroup) GetVpcId ¶
func (self *SSecurityGroup) GetVpcId() string
func (*SSecurityGroup) IsEmulated ¶
func (self *SSecurityGroup) IsEmulated() bool
func (*SSecurityGroup) Refresh ¶
func (self *SSecurityGroup) Refresh() error
func (*SSecurityGroup) SyncRules ¶
func (self *SSecurityGroup) SyncRules(common, inAdds, outAdds, inDels, outDels []cloudprovider.SecurityRule) error
type SSecurityGroupRule ¶
type SSecurityGroupRule struct { PortRangeMax int64 `json:"port_range_max"` SecurityGroupID string `json:"security_group_id"` RemoteGroupId string `json:"remote_group_id"` Description string `json:"description"` RemoteIPPrefix string `json:"remote_ip_prefix"` Protocol string `json:"protocol"` Ethertype string `json:"ethertype"` UpdatedAt string `json:"updated_at"` Direction string `json:"direction"` TenantID string `json:"tenant_id"` ID string `json:"id"` ProjectID string `json:"project_id"` PortRangeMin int64 `json:"port_range_min"` CreatedAt string `json:"created_at"` // contains filtered or unexported fields }
type SStorage ¶
type SStorage struct { multicloud.SStorageBase CtyunTags // contains filtered or unexported fields }
func (*SStorage) CreateIDisk ¶
func (self *SStorage) CreateIDisk(conf *cloudprovider.DiskCreateConfig) (cloudprovider.ICloudDisk, error)
func (*SStorage) GetCapacityMB ¶
func (*SStorage) GetCapacityUsedMB ¶
func (*SStorage) GetEnabled ¶
func (*SStorage) GetGlobalId ¶
func (*SStorage) GetIDiskById ¶
func (self *SStorage) GetIDiskById(idStr string) (cloudprovider.ICloudDisk, error)
func (*SStorage) GetIDisks ¶
func (self *SStorage) GetIDisks() ([]cloudprovider.ICloudDisk, error)
http://ctyun-api-url/apiproxy/v3/ondemand/queryVolumes
http://ctyun-api-url/apiproxy/v3/queryDataDisks
func (*SStorage) GetIStoragecache ¶
func (self *SStorage) GetIStoragecache() cloudprovider.ICloudStoragecache
func (*SStorage) GetIZone ¶
func (self *SStorage) GetIZone() cloudprovider.ICloudZone
func (*SStorage) GetMediumType ¶
func (*SStorage) GetMountPoint ¶
func (*SStorage) GetStorageConf ¶
func (self *SStorage) GetStorageConf() jsonutils.JSONObject
func (*SStorage) GetStorageType ¶
func (*SStorage) IsEmulated ¶
func (*SStorage) IsSysDiskStore ¶
type SStoragecache ¶
type SStoragecache struct { multicloud.SResourceBase CtyunTags // contains filtered or unexported fields }
func (*SStoragecache) CreateIImage ¶
func (self *SStoragecache) CreateIImage(snapshotId, imageName, osType, imageDesc string) (cloudprovider.ICloudImage, error)
func (*SStoragecache) DownloadImage ¶
func (self *SStoragecache) DownloadImage(userCred mcclient.TokenCredential, imageId string, extId string, path string) (jsonutils.JSONObject, error)
func (*SStoragecache) GetGlobalId ¶
func (self *SStoragecache) GetGlobalId() string
func (*SStoragecache) GetICloudImages ¶
func (self *SStoragecache) GetICloudImages() ([]cloudprovider.ICloudImage, error)
func (*SStoragecache) GetICustomizedCloudImages ¶
func (self *SStoragecache) GetICustomizedCloudImages() ([]cloudprovider.ICloudImage, error)
func (*SStoragecache) GetIImageById ¶
func (self *SStoragecache) GetIImageById(extId string) (cloudprovider.ICloudImage, error)
func (*SStoragecache) GetId ¶
func (self *SStoragecache) GetId() string
func (*SStoragecache) GetName ¶
func (self *SStoragecache) GetName() string
func (*SStoragecache) GetPath ¶
func (self *SStoragecache) GetPath() string
func (*SStoragecache) GetStatus ¶
func (self *SStoragecache) GetStatus() string
func (*SStoragecache) IsEmulated ¶
func (self *SStoragecache) IsEmulated() bool
func (*SStoragecache) Refresh ¶
func (self *SStoragecache) Refresh() error
func (*SStoragecache) UploadImage ¶
func (self *SStoragecache) UploadImage(ctx context.Context, userCred mcclient.TokenCredential, image *cloudprovider.SImageCreateOption, update func(progress float32)) (string, error)
type SVpc ¶
type SVpc struct { multicloud.SVpc CtyunTags ResVpcID string `json:"resVpcId"` Name string `json:"name"` CIDR string `json:"cidr"` ZoneID string `json:"zoneId"` ZoneName string `json:"zoneName"` VpcStatus string `json:"vpcStatus"` RegionID string `json:"regionId"` CreateDate int64 `json:"createDate"` // contains filtered or unexported fields }
func (*SVpc) GetCidrBlock ¶
func (*SVpc) GetGlobalId ¶
func (*SVpc) GetIRouteTableById ¶
func (self *SVpc) GetIRouteTableById(routeTableId string) (cloudprovider.ICloudRouteTable, error)
func (*SVpc) GetIRouteTables ¶
func (self *SVpc) GetIRouteTables() ([]cloudprovider.ICloudRouteTable, error)
func (*SVpc) GetISecurityGroups ¶
func (self *SVpc) GetISecurityGroups() ([]cloudprovider.ICloudSecurityGroup, error)
http://ctyun-api-url/apiproxy/v3/getSecurityGroupRules http://ctyun-api-url/apiproxy/v3/getSecurityGroups
func (*SVpc) GetIWireById ¶
func (self *SVpc) GetIWireById(wireId string) (cloudprovider.ICloudWire, error)
func (*SVpc) GetIWires ¶
func (self *SVpc) GetIWires() ([]cloudprovider.ICloudWire, error)
func (*SVpc) GetIsDefault ¶
func (*SVpc) GetRegion ¶
func (self *SVpc) GetRegion() cloudprovider.ICloudRegion
func (*SVpc) IsEmulated ¶
type SWire ¶
type SWire struct { multicloud.SResourceBase CtyunTags // contains filtered or unexported fields }
func (*SWire) CreateINetwork ¶
func (self *SWire) CreateINetwork(opts *cloudprovider.SNetworkCreateOptions) (cloudprovider.ICloudNetwork, error)
func (*SWire) GetBandwidth ¶
func (*SWire) GetGlobalId ¶
func (*SWire) GetINetworkById ¶
func (self *SWire) GetINetworkById(netid string) (cloudprovider.ICloudNetwork, error)
func (*SWire) GetINetworks ¶
func (self *SWire) GetINetworks() ([]cloudprovider.ICloudNetwork, error)
func (*SWire) GetIVpc ¶
func (self *SWire) GetIVpc() cloudprovider.ICloudVpc
func (*SWire) GetIZone ¶
func (self *SWire) GetIZone() cloudprovider.ICloudZone
func (*SWire) IsEmulated ¶
type SZone ¶
type SZone struct { multicloud.SResourceBase CtyunTags RegionID string `json:"regionId"` ZoneID string `json:"zoneId"` ZoneName string `json:"zoneName"` ZoneType string `json:"zoneType"` // contains filtered or unexported fields }
func (*SZone) GetGlobalId ¶
func (*SZone) GetI18n ¶
func (self *SZone) GetI18n() cloudprovider.SModelI18nTable
func (*SZone) GetIHostById ¶
func (self *SZone) GetIHostById(id string) (cloudprovider.ICloudHost, error)
func (*SZone) GetIHosts ¶
func (self *SZone) GetIHosts() ([]cloudprovider.ICloudHost, error)
func (*SZone) GetIRegion ¶
func (self *SZone) GetIRegion() cloudprovider.ICloudRegion
func (*SZone) GetIStorageById ¶
func (self *SZone) GetIStorageById(id string) (cloudprovider.ICloudStorage, error)
func (*SZone) GetIStorages ¶
func (self *SZone) GetIStorages() ([]cloudprovider.ICloudStorage, error)
func (*SZone) GetIWires ¶
func (self *SZone) GetIWires() ([]cloudprovider.ICloudWire, error)
func (*SZone) IsEmulated ¶
type ScheduledPolicy ¶
type SecurityGroup ¶
type SecurityGroup struct {
Name string `json:"name"`
}
type SecurityGroupID ¶
type SecurityGroupID struct {
ID string `json:"id"`
}