Documentation ¶
Overview ¶
Package ucompshare include resources of ucloud ucompshare product
See also
- API: https://docs.ucloud.cn/api/ucompshare-api/index
- Product: https://www.ucloud.cn/site/product/ucompshare.html
for detail.
Index ¶
- type Bundle
- type CreateULHostInstanceRequest
- type CreateULHostInstanceResponse
- type DescribeULHostBundlesRequest
- type DescribeULHostBundlesResponse
- type DescribeULHostInstanceRequest
- type DescribeULHostInstanceResponse
- type GetULHostInstancePriceRequest
- type GetULHostInstancePriceResponse
- type GetULHostRenewPriceRequest
- type GetULHostRenewPriceResponse
- type ModifyULHostAttributeRequest
- type ModifyULHostAttributeResponse
- type PoweroffULHostInstanceRequest
- type PoweroffULHostInstanceResponse
- type RebootULHostInstanceRequest
- type RebootULHostInstanceResponse
- type ReinstallULHostInstanceRequest
- type ReinstallULHostInstanceResponse
- type ResetULHostInstancePasswordRequest
- type ResetULHostInstancePasswordResponse
- type StartULHostInstanceRequest
- type StartULHostInstanceResponse
- type StopULHostInstanceRequest
- type StopULHostInstanceResponse
- type TerminateULHostInstanceRequest
- type TerminateULHostInstanceResponse
- type UCompShareClient
- func (c *UCompShareClient) CreateULHostInstance(req *CreateULHostInstanceRequest) (*CreateULHostInstanceResponse, error)
- func (c *UCompShareClient) DescribeULHostBundles(req *DescribeULHostBundlesRequest) (*DescribeULHostBundlesResponse, error)
- func (c *UCompShareClient) DescribeULHostInstance(req *DescribeULHostInstanceRequest) (*DescribeULHostInstanceResponse, error)
- func (c *UCompShareClient) GetULHostInstancePrice(req *GetULHostInstancePriceRequest) (*GetULHostInstancePriceResponse, error)
- func (c *UCompShareClient) GetULHostRenewPrice(req *GetULHostRenewPriceRequest) (*GetULHostRenewPriceResponse, error)
- func (c *UCompShareClient) ModifyULHostAttribute(req *ModifyULHostAttributeRequest) (*ModifyULHostAttributeResponse, error)
- func (c *UCompShareClient) NewCreateULHostInstanceRequest() *CreateULHostInstanceRequest
- func (c *UCompShareClient) NewDescribeULHostBundlesRequest() *DescribeULHostBundlesRequest
- func (c *UCompShareClient) NewDescribeULHostInstanceRequest() *DescribeULHostInstanceRequest
- func (c *UCompShareClient) NewGetULHostInstancePriceRequest() *GetULHostInstancePriceRequest
- func (c *UCompShareClient) NewGetULHostRenewPriceRequest() *GetULHostRenewPriceRequest
- func (c *UCompShareClient) NewModifyULHostAttributeRequest() *ModifyULHostAttributeRequest
- func (c *UCompShareClient) NewPoweroffULHostInstanceRequest() *PoweroffULHostInstanceRequest
- func (c *UCompShareClient) NewRebootULHostInstanceRequest() *RebootULHostInstanceRequest
- func (c *UCompShareClient) NewReinstallULHostInstanceRequest() *ReinstallULHostInstanceRequest
- func (c *UCompShareClient) NewResetULHostInstancePasswordRequest() *ResetULHostInstancePasswordRequest
- func (c *UCompShareClient) NewStartULHostInstanceRequest() *StartULHostInstanceRequest
- func (c *UCompShareClient) NewStopULHostInstanceRequest() *StopULHostInstanceRequest
- func (c *UCompShareClient) NewTerminateULHostInstanceRequest() *TerminateULHostInstanceRequest
- func (c *UCompShareClient) PoweroffULHostInstance(req *PoweroffULHostInstanceRequest) (*PoweroffULHostInstanceResponse, error)
- func (c *UCompShareClient) RebootULHostInstance(req *RebootULHostInstanceRequest) (*RebootULHostInstanceResponse, error)
- func (c *UCompShareClient) ReinstallULHostInstance(req *ReinstallULHostInstanceRequest) (*ReinstallULHostInstanceResponse, error)
- func (c *UCompShareClient) ResetULHostInstancePassword(req *ResetULHostInstancePasswordRequest) (*ResetULHostInstancePasswordResponse, error)
- func (c *UCompShareClient) StartULHostInstance(req *StartULHostInstanceRequest) (*StartULHostInstanceResponse, error)
- func (c *UCompShareClient) StopULHostInstance(req *StopULHostInstanceRequest) (*StopULHostInstanceResponse, error)
- func (c *UCompShareClient) TerminateULHostInstance(req *TerminateULHostInstanceRequest) (*TerminateULHostInstanceResponse, error)
- type UHostIPSet
- type ULHostDiskSet
- type ULHostInstanceSet
- type ULHostPriceSet
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Bundle ¶
type Bundle struct { // 外网带宽。单位:Mbps。 Bandwidth int // 套餐ID。 BundleId string // CPU核数。 CPU int // 内存大小。单位:MB。 Memory int // 系统盘大小。单位:GB。 SysDiskSpace int // 流量包大小。单位:GB。 TrafficPacket int }
Bundle - 轻量应用云主机套餐
type CreateULHostInstanceRequest ¶
type CreateULHostInstanceRequest struct { request.CommonBase // 套餐ID。如:"ulh.c1m1s40b30t800" BundleId *string `required:"true"` // 计费模式。枚举值: \\ > Year,按年付费; \\ > Month,按月付费;默认:Month ChargeType *string `required:"false"` // 主机代金券ID。请通过DescribeCoupon接口查询,或登录用户中心查看 CouponId *string `required:"false"` // 镜像ID。 请通过 [DescribeImage](describe_image.html)获取 ImageId *string `required:"true"` // 轻量应用主机名称。默认:套餐ID。请遵照[[api:uhost-api:specification|字段规范]]设定实例名称。 Name *string `required:"false"` // ULHost密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,举例如下:# echo -n Password1 | base64 Password *string `required:"true"` // 购买时长。默认:1。不支持购买到月末 Quantity *int `required:"false"` // 防火墙ID,默认:Web推荐防火墙。如何查询SecurityGroupId请参见 [DescribeFirewall](api/unet-api/describe_firewall.html)。 SecurityGroupId *string `required:"false"` // 子网 ID。默认为当前地域的默认子网。 SubnetId *string `required:"false"` // VPC ID。默认为当前地域的默认VPC。 VPCId *string `required:"false"` }
CreateULHostInstanceRequest is request schema for CreateULHostInstance action
type CreateULHostInstanceResponse ¶
type CreateULHostInstanceResponse struct { response.CommonBase // 错误信息 Message string // 实例ID ULHostId string }
CreateULHostInstanceResponse is response schema for CreateULHostInstance action
type DescribeULHostBundlesRequest ¶
type DescribeULHostBundlesRequest struct {
request.CommonBase
}
DescribeULHostBundlesRequest is request schema for DescribeULHostBundles action
type DescribeULHostBundlesResponse ¶
type DescribeULHostBundlesResponse struct { response.CommonBase // 套餐列表 Bundles []Bundle // 错误信息 Message string }
DescribeULHostBundlesResponse is response schema for DescribeULHostBundles action
type DescribeULHostInstanceRequest ¶
type DescribeULHostInstanceRequest struct { request.CommonBase // 返回数据长度,默认为20,最大100 Limit *int `required:"false"` // 列表起始位置偏移量,默认为0 Offset *int `required:"false"` // 【数组】轻量应用云主机ID。 ULHostIds []string `required:"false"` }
DescribeULHostInstanceRequest is request schema for DescribeULHostInstance action
type DescribeULHostInstanceResponse ¶
type DescribeULHostInstanceResponse struct { response.CommonBase // 错误信息 Message string // 实例列表 ULHostInstanceSets []ULHostInstanceSet }
DescribeULHostInstanceResponse is response schema for DescribeULHostInstance action
type GetULHostInstancePriceRequest ¶
type GetULHostInstancePriceRequest struct { request.CommonBase // 套餐ID BundleId *string `required:"true"` // 获取指定计费模式的价格。枚举值:\\ > Year,按年付费; \\ > Month。未指定时,返回所有计费模式价格 ChargeType *string `required:"false"` // 购买台数,范围[1,5]。默认:1 Count *int `required:"false"` // 购买时长。默认: 1。不支持购买到月末 Quantity *int `required:"false"` }
GetULHostInstancePriceRequest is request schema for GetULHostInstancePrice action
type GetULHostInstancePriceResponse ¶
type GetULHostInstancePriceResponse struct { response.CommonBase // 错误信息 Message string // PriceSet []ULHostPriceSet }
GetULHostInstancePriceResponse is response schema for GetULHostInstancePrice action
type GetULHostRenewPriceRequest ¶
type GetULHostRenewPriceRequest struct { request.CommonBase // 计费类型。支持:Year/Month;默认:Month ChargeType *string `required:"false"` // ULHost实例ID ULHostId *string `required:"true"` }
GetULHostRenewPriceRequest is request schema for GetULHostRenewPrice action
type GetULHostRenewPriceResponse ¶
type GetULHostRenewPriceResponse struct { response.CommonBase // PriceSet []ULHostPriceSet }
GetULHostRenewPriceResponse is response schema for GetULHostRenewPrice action
type ModifyULHostAttributeRequest ¶
type ModifyULHostAttributeRequest struct { request.CommonBase // 名称。和Remark至少选择一个进行修改 Name *string `required:"false"` // 备注。和Name至少选择一个进行修改 Remark *string `required:"false"` // ULHost实例Id ULHostId *string `required:"true"` }
ModifyULHostAttributeRequest is request schema for ModifyULHostAttribute action
type ModifyULHostAttributeResponse ¶
type ModifyULHostAttributeResponse struct { response.CommonBase // 错误信息 Message string // ULHost实例Id ULHostId string }
ModifyULHostAttributeResponse is response schema for ModifyULHostAttribute action
type PoweroffULHostInstanceRequest ¶
type PoweroffULHostInstanceRequest struct { request.CommonBase // ULHost实例ID ULHostId *string `required:"true"` }
PoweroffULHostInstanceRequest is request schema for PoweroffULHostInstance action
type PoweroffULHostInstanceResponse ¶
type PoweroffULHostInstanceResponse struct { response.CommonBase // ULHost实例ID ULHostId string }
PoweroffULHostInstanceResponse is response schema for PoweroffULHostInstance action
type RebootULHostInstanceRequest ¶
type RebootULHostInstanceRequest struct { request.CommonBase // ULHost实例ID ULHostId *string `required:"true"` }
RebootULHostInstanceRequest is request schema for RebootULHostInstance action
type RebootULHostInstanceResponse ¶
type RebootULHostInstanceResponse struct { response.CommonBase // ULHost实例ID ULHostId string }
RebootULHostInstanceResponse is response schema for RebootULHostInstance action
type ReinstallULHostInstanceRequest ¶
type ReinstallULHostInstanceRequest struct { request.CommonBase // 镜像Id。暂不支持使用自定义镜像重装 ImageId *string `required:"true"` // 登陆密码 Password *string `required:"true"` // 实例Id ULHostId *string `required:"true"` }
ReinstallULHostInstanceRequest is request schema for ReinstallULHostInstance action
type ReinstallULHostInstanceResponse ¶
type ReinstallULHostInstanceResponse struct { response.CommonBase // 错误信息 Message string // 实例Id ULHostId string }
ReinstallULHostInstanceResponse is response schema for ReinstallULHostInstance action
type ResetULHostInstancePasswordRequest ¶
type ResetULHostInstancePasswordRequest struct { request.CommonBase // ULHost新密码(密码格式使用BASE64编码) Password *string `required:"true"` // ULHost实例ID ULHostId *string `required:"true"` }
ResetULHostInstancePasswordRequest is request schema for ResetULHostInstancePassword action
type ResetULHostInstancePasswordResponse ¶
type ResetULHostInstancePasswordResponse struct { response.CommonBase // ULHost实例ID ULHostId string }
ResetULHostInstancePasswordResponse is response schema for ResetULHostInstancePassword action
type StartULHostInstanceRequest ¶
type StartULHostInstanceRequest struct { request.CommonBase // ULHost实例ID ULHostId *string `required:"true"` }
StartULHostInstanceRequest is request schema for StartULHostInstance action
type StartULHostInstanceResponse ¶
type StartULHostInstanceResponse struct { response.CommonBase // ULHost实例ID ULHostId string }
StartULHostInstanceResponse is response schema for StartULHostInstance action
type StopULHostInstanceRequest ¶
type StopULHostInstanceRequest struct { request.CommonBase // ULHost实例ID。 ULHostId *string `required:"true"` }
StopULHostInstanceRequest is request schema for StopULHostInstance action
type StopULHostInstanceResponse ¶
type StopULHostInstanceResponse struct { response.CommonBase // ULHost实例ID ULHostId string }
StopULHostInstanceResponse is response schema for StopULHostInstance action
type TerminateULHostInstanceRequest ¶
type TerminateULHostInstanceRequest struct { request.CommonBase // 删除主机时是否同时删除挂载的数据盘。默认为false。 ReleaseUDisk *bool `required:"false"` // ULHost资源Id ULHostId *string `required:"true"` }
TerminateULHostInstanceRequest is request schema for TerminateULHostInstance action
type TerminateULHostInstanceResponse ¶
type TerminateULHostInstanceResponse struct { response.CommonBase // 用于判断主机删除时是否进入回收站。放入回收站:"Yes", 彻底删除:“No”。 InRecycle string // ULHost 实例 Id ULHostId string }
TerminateULHostInstanceResponse is response schema for TerminateULHostInstance action
type UCompShareClient ¶
type UCompShareClient struct {
}UCompShareClient is the client of UCompShare
func NewClient ¶
func NewClient(config *ucloud.Config, credential *auth.Credential) *UCompShareClient
NewClient will return a instance of UCompShareClient
func (*UCompShareClient) CreateULHostInstance ¶
func (c *UCompShareClient) CreateULHostInstance(req *CreateULHostInstanceRequest) (*CreateULHostInstanceResponse, error)
API: CreateULHostInstance
创建轻量应用云主机
func (*UCompShareClient) DescribeULHostBundles ¶
func (c *UCompShareClient) DescribeULHostBundles(req *DescribeULHostBundlesRequest) (*DescribeULHostBundlesResponse, error)
API: DescribeULHostBundles
获取轻量应用云主机套餐列表
func (*UCompShareClient) DescribeULHostInstance ¶
func (c *UCompShareClient) DescribeULHostInstance(req *DescribeULHostInstanceRequest) (*DescribeULHostInstanceResponse, error)
API: DescribeULHostInstance
获取轻量应用云主机列表
func (*UCompShareClient) GetULHostInstancePrice ¶
func (c *UCompShareClient) GetULHostInstancePrice(req *GetULHostInstancePriceRequest) (*GetULHostInstancePriceResponse, error)
API: GetULHostInstancePrice
获取轻量应用云主机套餐价格
func (*UCompShareClient) GetULHostRenewPrice ¶
func (c *UCompShareClient) GetULHostRenewPrice(req *GetULHostRenewPriceRequest) (*GetULHostRenewPriceResponse, error)
API: GetULHostRenewPrice
获取主机续费价格
func (*UCompShareClient) ModifyULHostAttribute ¶
func (c *UCompShareClient) ModifyULHostAttribute(req *ModifyULHostAttributeRequest) (*ModifyULHostAttributeResponse, error)
API: ModifyULHostAttribute
修改指定ULHost实例属性信息,包含名称和备注
func (*UCompShareClient) NewCreateULHostInstanceRequest ¶
func (c *UCompShareClient) NewCreateULHostInstanceRequest() *CreateULHostInstanceRequest
NewCreateULHostInstanceRequest will create request of CreateULHostInstance action.
func (*UCompShareClient) NewDescribeULHostBundlesRequest ¶
func (c *UCompShareClient) NewDescribeULHostBundlesRequest() *DescribeULHostBundlesRequest
NewDescribeULHostBundlesRequest will create request of DescribeULHostBundles action.
func (*UCompShareClient) NewDescribeULHostInstanceRequest ¶
func (c *UCompShareClient) NewDescribeULHostInstanceRequest() *DescribeULHostInstanceRequest
NewDescribeULHostInstanceRequest will create request of DescribeULHostInstance action.
func (*UCompShareClient) NewGetULHostInstancePriceRequest ¶
func (c *UCompShareClient) NewGetULHostInstancePriceRequest() *GetULHostInstancePriceRequest
NewGetULHostInstancePriceRequest will create request of GetULHostInstancePrice action.
func (*UCompShareClient) NewGetULHostRenewPriceRequest ¶
func (c *UCompShareClient) NewGetULHostRenewPriceRequest() *GetULHostRenewPriceRequest
NewGetULHostRenewPriceRequest will create request of GetULHostRenewPrice action.
func (*UCompShareClient) NewModifyULHostAttributeRequest ¶
func (c *UCompShareClient) NewModifyULHostAttributeRequest() *ModifyULHostAttributeRequest
NewModifyULHostAttributeRequest will create request of ModifyULHostAttribute action.
func (*UCompShareClient) NewPoweroffULHostInstanceRequest ¶
func (c *UCompShareClient) NewPoweroffULHostInstanceRequest() *PoweroffULHostInstanceRequest
NewPoweroffULHostInstanceRequest will create request of PoweroffULHostInstance action.
func (*UCompShareClient) NewRebootULHostInstanceRequest ¶
func (c *UCompShareClient) NewRebootULHostInstanceRequest() *RebootULHostInstanceRequest
NewRebootULHostInstanceRequest will create request of RebootULHostInstance action.
func (*UCompShareClient) NewReinstallULHostInstanceRequest ¶
func (c *UCompShareClient) NewReinstallULHostInstanceRequest() *ReinstallULHostInstanceRequest
NewReinstallULHostInstanceRequest will create request of ReinstallULHostInstance action.
func (*UCompShareClient) NewResetULHostInstancePasswordRequest ¶
func (c *UCompShareClient) NewResetULHostInstancePasswordRequest() *ResetULHostInstancePasswordRequest
NewResetULHostInstancePasswordRequest will create request of ResetULHostInstancePassword action.
func (*UCompShareClient) NewStartULHostInstanceRequest ¶
func (c *UCompShareClient) NewStartULHostInstanceRequest() *StartULHostInstanceRequest
NewStartULHostInstanceRequest will create request of StartULHostInstance action.
func (*UCompShareClient) NewStopULHostInstanceRequest ¶
func (c *UCompShareClient) NewStopULHostInstanceRequest() *StopULHostInstanceRequest
NewStopULHostInstanceRequest will create request of StopULHostInstance action.
func (*UCompShareClient) NewTerminateULHostInstanceRequest ¶
func (c *UCompShareClient) NewTerminateULHostInstanceRequest() *TerminateULHostInstanceRequest
NewTerminateULHostInstanceRequest will create request of TerminateULHostInstance action.
func (*UCompShareClient) PoweroffULHostInstance ¶
func (c *UCompShareClient) PoweroffULHostInstance(req *PoweroffULHostInstanceRequest) (*PoweroffULHostInstanceResponse, error)
API: PoweroffULHostInstance
直接关闭UHost实例电源,无需等待实例正常关闭。
func (*UCompShareClient) RebootULHostInstance ¶
func (c *UCompShareClient) RebootULHostInstance(req *RebootULHostInstanceRequest) (*RebootULHostInstanceResponse, error)
API: RebootULHostInstance
重新启动UHost实例。
func (*UCompShareClient) ReinstallULHostInstance ¶
func (c *UCompShareClient) ReinstallULHostInstance(req *ReinstallULHostInstanceRequest) (*ReinstallULHostInstanceResponse, error)
API: ReinstallULHostInstance
重装轻量应用云主机
func (*UCompShareClient) ResetULHostInstancePassword ¶
func (c *UCompShareClient) ResetULHostInstancePassword(req *ResetULHostInstancePasswordRequest) (*ResetULHostInstancePasswordResponse, error)
API: ResetULHostInstancePassword
重置轻量应用云主机管理员密码。
func (*UCompShareClient) StartULHostInstance ¶
func (c *UCompShareClient) StartULHostInstance(req *StartULHostInstanceRequest) (*StartULHostInstanceResponse, error)
API: StartULHostInstance
启动处于关闭状态的UHost实例。
func (*UCompShareClient) StopULHostInstance ¶
func (c *UCompShareClient) StopULHostInstance(req *StopULHostInstanceRequest) (*StopULHostInstanceResponse, error)
API: StopULHostInstance
指停止处于运行状态的ULHost实例
func (*UCompShareClient) TerminateULHostInstance ¶
func (c *UCompShareClient) TerminateULHostInstance(req *TerminateULHostInstanceRequest) (*TerminateULHostInstanceResponse, error)
API: TerminateULHostInstance
删除指定数据中心的ULHost实例。
type UHostIPSet ¶
type UHostIPSet struct { // IP对应的带宽, 单位: Mb (内网IP不显示带宽信息) Bandwidth int // 内网 Private 类型下,表示是否为默认网卡。true: 是默认网卡;其他值:不是。 Default string // IP地址 IP string // 外网IP资源ID 。(内网IP无对应的资源ID) IPId string // IPv4/IPv6; IPMode string // 内网 Private 类型下,当前网卡的Mac。 Mac string // 弹性网卡为默认网卡时,返回对应的 ID 值 NetworkInterfaceId string // IP地址对应的子网 ID。(北京一不支持,字段返回为空) SubnetId string // 国际: Internation,BGP: Bgp,内网: Private Type string // IP地址对应的VPC ID。(北京一不支持,字段返回为空) VPCId string // 当前EIP的权重。权重最大的为当前的出口IP。 Weight int }
UHostIPSet -
type ULHostDiskSet ¶
type ULHostDiskSet struct { // 磁盘Id DiskId string // 磁盘类型。如:"CLOUD_RSSD"、"CLOUD_SSD" DiskType string // 磁盘盘符。系统盘:"vda" Drive string // 是否为系统盘。是:"True";否:"False" IsBoot string // 磁盘大小。单位:GB Size int // 磁盘类型。系统盘:"Boot";数据盘:"Data" Type string }
ULHostDiskSet - 轻量应用主机的磁盘信息
type ULHostInstanceSet ¶
type ULHostInstanceSet struct { // 【数组】镜像包含的应用列表。 Apps []string // 是否自动续费。枚举值:Yes/No AutoRenew string // CPU核数。 CPU int // 计费模式。枚举值:Month/Year ChargeType string // 创建时间。Unix时间戳 CreateTime int // 磁盘信息 DiskSet []ULHostDiskSet // 过期时间。Unix时间戳 ExpireTime int // IP信息 IPSet []UHostIPSet // 镜像Id。 ImageId string // 镜像名称。 ImageName string // 是否过期。枚举值:Yes/No IsExpire string // 内存。单位:MB Memory int // 实例名称。默认套餐Id Name string // 备注。 Remark string // 实例状态。枚举值:\\ >初始化: Initializing; \\ >启动中: Starting; \\> 运行中: Running; \\> 关机中: Stopping; \\ >关机: Stopped \\ >安装失败: Install Fail; \\ >重启中: Rebooting; \\ > 未知(空字符串,获取状态超时或出错):"" State string // 业务组。 Tag string // 实例Id。 ULHostId string // 可用区。 Zone string }
ULHostInstanceSet - 轻量应用云主机详情
type ULHostPriceSet ¶
type ULHostPriceSet struct { // 计费模式 ChargeType string // 原价 OriginalPrice float64 // 价格 Price float64 }
ULHostPriceSet - 轻量应用主机价格详情