Documentation ¶
Overview ¶
Package api defines all APIs supported by the BEC service of BCE.
util.go - define the utilities for api package of BEC service
Index ¶
- Constants
- func Delete(cli bce.Client, dhr *PostHttpReq) error
- func Get(cli bce.Client, ghr *GetHttpReq) error
- func GetBachServiceDeleteURI() string
- func GetBachServiceOperateURI() string
- func GetDeleteServiceURI(serviceId string) string
- func GetLoadBalancerBatchURI() string
- func GetLoadBalancerURI() string
- func GetNodeInfoURI() string
- func GetServiceDetailURI(serviceId string) string
- func GetServiceMetricsURI(serviceId, metricsType string) string
- func GetServiceURI() string
- func GetStartServiceURI(serviceId, action string) string
- func GetUpdateServiceURI(serviceId string) string
- func GetVmImageURI() string
- func GetVmInstanceURI() string
- func GetVmServiceActionURI(serviceId, action string) string
- func GetVmServiceMetricsURI(serviceId, metricsType string) string
- func GetVmURI() string
- func Post(cli bce.Client, phr *PostHttpReq) error
- func PostOrPut(cli bce.Client, phr *PostHttpReq, req *bce.BceRequest) error
- func Put(cli bce.Client, phr *PostHttpReq) error
- type ActionInfoVo
- type Backends
- type BatchCreateBlbArgs
- type BatchCreateBlbMonitorArg
- type BatchCreateBlbMonitorResult
- type BatchCreateBlbResult
- type BatchDeleteBlbResult
- type BlbBackendPodBriefVo
- type BlbBindingForm
- type BlbInstanceVo
- type BlbMonitorArgs
- type BlbMonitorListResult
- type BlbMonitorResult
- type CityInfo
- type ConfigFile
- type ContainerDetails
- type CreateBlbArgs
- type CreateBlbBindingArgs
- type CreateBlbBindingResult
- type CreateBlbResult
- type CreateServiceArgs
- type CreateServiceResult
- type CreateVmImageArgs
- type CreateVmImageResult
- type CreateVmPrivateIpForm
- type CreateVmServiceArgs
- type CreateVmServiceResult
- type DeleteBlbBindPodArgs
- type DeleteBlbBindPodResult
- type DeleteBlbResult
- type DeleteVmPrivateIpForm
- type DeleteVmServiceArgs
- type DeleteVmServiceResult
- type DeploymentInstance
- type DiskType
- type DnsConfig
- type EmptyDir
- type GetBecAvailableNodeInfoVoResult
- type GetBlbBackendBindingStsListResult
- type GetBlbBackendPodListResult
- type GetBlbListResult
- type GetHttpReq
- type GetNodeVmInstanceListResult
- type GetServiceArgs
- type GetVmServiceDetailArgs
- type GpuRequest
- type HealthCheck
- type ImageDetail
- type ImageRegistrySecret
- type ImageType
- type IpInfo
- type IpPackageVo
- type IpamResultVo
- type KeyConfig
- type LbDeployPo
- type LbMode
- type ListDeploymentArgs
- type ListRequest
- type ListServiceResult
- type ListVmImageArgs
- type ListVmImageResult
- type ListVmServiceArgs
- type ListVmServiceResult
- type Listeners
- type LogCollectDetail
- type LogicPageVmInstanceResult
- type Metric
- type MetricsType
- type NetworkConfig
- type Networks
- type OperateVmDeploymentResult
- type OperationVo
- type OrderModel
- type Port
- type PortGroup
- type PostHttpReq
- type Protocol
- type Region
- type RegionInfo
- type ReinstallVmInstanceArg
- type ReinstallVmInstanceResult
- type ResourceBriefVo
- type ResourceStatus
- type Secret
- type ServiceAction
- type ServiceActionResult
- type ServiceBatchOperateArgs
- type ServiceBatchOperateResult
- type ServiceBriefVo
- type ServiceDetailsVo
- type ServiceMetricsResult
- type ServiceProvider
- type ServiceProviderInfo
- type Stats
- type SystemVolumeConfig
- type Tag
- type UpdateBecVmForm
- type UpdateBindPodWeightArgs
- type UpdateBindPodWeightResult
- type UpdateBlbArgs
- type UpdateBlbResult
- type UpdateServiceArgs
- type UpdateServiceResult
- type UpdateServiceType
- type UpdateVmDeploymentArgs
- type UpdateVmDeploymentResult
- type UpdateVmImageArgs
- type UpdateVmServiceArgs
- type UpdateVmServiceResult
- type UpdateVmType
- type V1ConfigMapKeySelector
- type V1ContainerPort
- type V1EnvVar
- type V1EnvVarSource
- type V1ObjectFieldSelector
- type V1ResourceFieldSelector
- type V1SecretKeySelector
- type V1VolumeMount
- type VmConfigResult
- type VmImageOperateResult
- type VmImageVo
- type VmInstanceBatchOperateAction
- type VmInstanceBriefVo
- type VmInstanceDetailsVo
- type VmInstanceIdVo
- type VmPrivateIpResult
- type VmServiceAction
- type VmServiceActionResult
- type VmServiceBatchAction
- type VmServiceBatchActionArgs
- type VmServiceBatchActionResult
- type VmServiceBriefVo
- type VmServiceDetailsVo
- type Volume
- type VolumeClaimTemplates
- type VolumeConfig
Constants ¶
View Source
const ( ResourceStatusStarting = "STARTING" ResourceStatusRunning = "RUNNING" ResourceStatusException = "EXCEPTION" ResourceStatusFailed = "FAILED" ResourceStatusUnknown = "UNKNOWN" ResourceStatusTerminated = "TERMINATED" ResourceStatusWaiting = "WAITING" ResourceStatusStop = "STOP" ResourceStatusStopping = "STOPPING" ResourceStatusTerminating = "TERMINATING" ResourceStatusNormal = "NORMAL" // part of status for vm instant ResourceStatusCreating = "CREATING" ResourceStatusStopped = "STOPPED" ResourceStatusRestarting = "RESTARTING" ResourceStatusReinstalling = "REINSTALLING" ResourceStatusImaging = "IMAGING" // part of status for lb ResourceStatusPending = "PENDING" ResourceStatusBinding = "BINDING" )
View Source
const ( URI_PREFIX = bce.URI_PREFIX + "v1" DEFAULT_BEC_DOMAIN = "bec." + bce.DEFAULT_REGION + bce.DEFAULT_DOMAIN REQUEST_SERVICE_URL = URI_PREFIX + "/service" REQUEST_VM_URL = URI_PREFIX + "/vm" + "/service" REQUEST_VM_IMAGE_URL = URI_PREFIX + "/vm" + "/image" REQUEST_LOADBALANCER_URL = URI_PREFIX + "/blb" REQUEST_VM_INSTANCE_URL = URI_PREFIX + "/vm/instance" REQUEST_NODE_URL = URI_PREFIX + "/node" )
Variables ¶
This section is empty.
Functions ¶
func GetBachServiceDeleteURI ¶
func GetBachServiceDeleteURI() string
func GetBachServiceOperateURI ¶
func GetBachServiceOperateURI() string
func GetDeleteServiceURI ¶
func GetLoadBalancerBatchURI ¶
func GetLoadBalancerBatchURI() string
func GetLoadBalancerURI ¶
func GetLoadBalancerURI() string
func GetNodeInfoURI ¶ added in v0.9.72
func GetNodeInfoURI() string
func GetServiceDetailURI ¶
func GetServiceMetricsURI ¶
func GetServiceURI ¶
func GetServiceURI() string
func GetStartServiceURI ¶
func GetUpdateServiceURI ¶
func GetVmImageURI ¶
func GetVmImageURI() string
func GetVmInstanceURI ¶
func GetVmInstanceURI() string
func GetVmServiceActionURI ¶
func GetVmServiceMetricsURI ¶
func PostOrPut ¶
func PostOrPut(cli bce.Client, phr *PostHttpReq, req *bce.BceRequest) error
Types ¶
type ActionInfoVo ¶
type BatchCreateBlbArgs ¶
type BatchCreateBlbArgs struct { LbType string `json:"lbType,omitempty"` PaymentMethod string `json:"paymentMethod,omitempty"` RegionSelection string `json:"regionSelection,omitempty"` DeployInstances *[]DeploymentInstance `json:"deployInstances,omitempty"` BlbName string `json:"blbName,omitempty"` NeedPublicIp bool `json:"needPublicIp,omitempty"` BandwidthInMbpsLimit int `json:"bandwidthInMbpsLimit,omitempty"` Tags *[]Tag `json:"tags,omitempty"` Listeners *[]Listeners `json:"listeners,omitempty"` }
type BatchCreateBlbMonitorArg ¶
type BatchCreateBlbMonitorArg struct { Protocol Protocol `json:"protocol,omitempty"` PortGroups *[]PortGroup `json:"portGroups,omitempty"` LbMode LbMode `json:"lbMode,omitempty"` KeepaliveTimeout int `json:"keepaliveTimeout,omitempty"` HealthCheck *HealthCheck `json:"healthCheck,omitempty"` EnableCipTTM bool `json:"enableCipTTM,omitempty"` EnableVipTTM bool `json:"enableVipTTM,omitempty"` }
type BatchCreateBlbResult ¶
type BatchCreateBlbResult struct { Result bool `json:"result"` Action string `json:"action"` Details []BlbInstanceVo `json:"details"` }
type BatchDeleteBlbResult ¶
type BatchDeleteBlbResult struct { Result bool `json:"result"` Action string `json:"action"` Details []OperationVo `json:"details"` }
type BlbBackendPodBriefVo ¶
type BlbBindingForm ¶
type BlbInstanceVo ¶
type BlbInstanceVo struct { BlbId string `json:"blbId"` BlbName string `json:"blbName"` Status string `json:"status"` LbType string `json:"lbType"` Region Region `json:"region"` ServiceProvider ServiceProvider `json:"serviceProvider"` City string `json:"city"` PublicIp string `json:"publicIp"` CmPublicIP string `json:"cmPublicIP"` CtPublicIP string `json:"ctPublicIP"` UnPublicIP string `json:"unPublicIP"` InternalIp string `json:"internalIp"` Ports []Listeners `json:"ports"` PodCount int `json:"podCount"` BandwidthInMbpsLimit int `json:"bandwidthInMbpsLimit"` CreateTime string `json:"createTime"` }
type BlbMonitorArgs ¶
type BlbMonitorArgs struct { FrontendPort *Port `json:"frontendPort,omitempty"` BackendPort int `json:"backendPort,omitempty"` LbMode LbMode `json:"lbMode,omitempty"` KeepaliveTimeout int `json:"keepaliveTimeout,omitempty"` HealthCheck *HealthCheck `json:"healthCheck,omitempty"` EnableCipTTM bool `json:"enableCipTTM,omitempty"` EnableVipTTM bool `json:"enableVipTTM,omitempty"` }
type BlbMonitorListResult ¶
type BlbMonitorResult ¶
type CityInfo ¶ added in v0.9.72
type CityInfo struct { City string `json:"city"` Name string `json:"name"` ServiceProviderList []ServiceProviderInfo `json:"serviceProviderList"` }
type ConfigFile ¶
type ConfigFile EmptyDir
type ContainerDetails ¶
type ContainerDetails struct { Name string `json:"name,omitempty"` ImageVersion string `json:"imageVersion,omitempty"` ImageAddress string `json:"imageAddress,omitempty"` Memory int `json:"memory,omitempty"` Cpu int `json:"cpu,omitempty"` Gpu int `json:"gpu,omitempty"` WorkingDir string `json:"workingDir,omitempty"` Commands []string `json:"commands,omitempty"` Args []string `json:"args,omitempty"` VolumeMounts *[]V1VolumeMount `json:"volumeMounts,omitempty"` Ports *[]V1ContainerPort `json:"ports,omitempty"` Envs *[]V1EnvVar `json:"envs,omitempty"` }
type CreateBlbArgs ¶
type CreateBlbArgs struct { LbType string `json:"lbType,omitempty"` PaymentMethod string `json:"paymentMethod,omitempty"` RegionSelection string `json:"regionSelection,omitempty"` Region Region `json:"region,omitempty"` City string `json:"city,omitempty"` ServiceProvider ServiceProvider `json:"serviceProvider,omitempty"` BlbName string `json:"blbName,omitempty"` NeedPublicIp bool `json:"needPublicIp,omitempty"` BandwidthInMbpsLimit int `json:"bandwidthInMbpsLimit,omitempty"` Tags *[]Tag `json:"tags,omitempty"` Listeners *[]Listeners `json:"listeners,omitempty"` }
type CreateBlbBindingArgs ¶
type CreateBlbBindingArgs struct {
BindingForms *[]BlbBindingForm `json:"bindingForms,omitempty"`
}
type CreateBlbBindingResult ¶
type CreateBlbResult ¶
type CreateBlbResult struct { Result bool `json:"result"` Action string `json:"action"` Details BlbInstanceVo `json:"details"` }
type CreateServiceArgs ¶
type CreateServiceArgs struct { ServiceName string `json:"serviceName,omitempty"` PaymentMethod string `json:"paymentMethod,omitempty"` ContainerGroupName string `json:"containerGroupName,omitempty"` Containers *[]ContainerDetails `json:"containers,omitempty"` ImageRegistrySecrets *[]ImageRegistrySecret `json:"imageRegistrySecrets,omitempty"` Volumes *Volume `json:"volumes,omitempty"` NeedPublicIp bool `json:"needPublicIp,omitempty"` Bandwidth int `json:"bandwidth,omitempty"` Tags *[]Tag `json:"tags,omitempty"` DeployInstances *[]DeploymentInstance `json:"deployInstances,omitempty"` LogCollectDetail *LogCollectDetail `json:"logCollectDetail,omitempty"` }
type CreateServiceResult ¶
type CreateServiceResult struct { Details ServiceBriefVo `json:"details"` Result bool `json:"result"` Action string `json:"action"` }
type CreateVmImageArgs ¶
type CreateVmImageResult ¶
type CreateVmPrivateIpForm ¶
type CreateVmServiceArgs ¶
type CreateVmServiceArgs struct { ServiceName string `json:"serviceName,omitempty"` VmName string `json:"vmName,omitempty"` NeedIpv6PublicIp bool `json:"needIpv6PublicIp,omitempty"` DisableIntranet bool `json:"disableIntranet,omitempty"` DisableCloudInit bool `json:"disableCloudInit,omitempty"` PaymentMethod string `json:"paymentMethod,omitempty"` NeedPublicIp bool `json:"needPublicIp,omitempty"` Bandwidth int `json:"bandwidth,omitempty"` DeployInstances *[]DeploymentInstance `json:"deployInstances,omitempty"` Cpu int `json:"cpu,omitempty"` Memory int `json:"memory,omitempty"` Gpu *GpuRequest `json:"gpu,omitempty"` ImageId string `json:"imageId,omitempty"` ImageType ImageType `json:"imageType,omitempty"` DataVolumeList *[]VolumeConfig `json:"dataVolumeList,omitempty"` SystemVolume *SystemVolumeConfig `json:"systemVolume,omitempty"` NetworkConfigList *[]NetworkConfig `json:"networkConfigList,omitempty"` AdminPass string `json:"adminPass,omitempty"` DnsConfig *DnsConfig `json:"dnsConfig,omitempty"` KeyConfig *KeyConfig `json:"keyConfig,omitempty"` }
type CreateVmServiceResult ¶
type CreateVmServiceResult struct { Details VmServiceBriefVo `json:"details"` Result bool `json:"result"` Action string `json:"action"` }
type DeleteBlbBindPodArgs ¶
type DeleteBlbBindPodResult ¶
type DeleteBlbResult ¶
type DeleteVmPrivateIpForm ¶
type DeleteVmPrivateIpForm struct {
PrivateIps []string `json:"privateIps,omitempty"`
}
type DeleteVmServiceArgs ¶
type DeleteVmServiceArgs struct {
ServiceId string `json:"serviceId"`
}
type DeleteVmServiceResult ¶
type DeploymentInstance ¶
type DeploymentInstance struct { Region Region `json:"region,omitempty"` ServiceProvider ServiceProvider `json:"serviceProvider,omitempty"` Replicas int `json:"replicas,omitempty"` City string `json:"city,omitempty"` }
type GetBecAvailableNodeInfoVoResult ¶ added in v0.9.72
type GetBecAvailableNodeInfoVoResult struct {
RegionList []RegionInfo `json:"regionList"`
}
type GetBlbBackendBindingStsListResult ¶
type GetBlbBackendBindingStsListResult struct { Orders []OrderModel `json:"orders"` OrderBy string `json:"orderBy"` Order string `json:"order"` PageNo int `json:"pageNo"` PageSize int `json:"pageSize"` TotalCount int `json:"totalCount"` Result []LbDeployPo `json:"result"` }
type GetBlbBackendPodListResult ¶
type GetBlbBackendPodListResult struct { Orders []OrderModel `json:"orders"` OrderBy string `json:"orderBy"` Order string `json:"order"` PageNo int `json:"pageNo"` PageSize int `json:"pageSize"` TotalCount int `json:"totalCount"` Result []BlbBackendPodBriefVo `json:"result"` }
type GetBlbListResult ¶
type GetBlbListResult struct { Orders []OrderModel `json:"orders"` OrderBy string `json:"orderBy"` PageNo int `json:"pageNo"` PageSize int `json:"pageSize"` TotalCount int `json:"totalCount"` Result []BlbInstanceVo `json:"result"` }
type GetHttpReq ¶
type GetNodeVmInstanceListResult ¶
type GetNodeVmInstanceListResult struct { Result []VmInstanceBriefVo `json:"result"` Success bool `json:"success"` }
type GetServiceArgs ¶
type GetServiceArgs struct {
ServiceId string
}
type GetVmServiceDetailArgs ¶
type GetVmServiceDetailArgs struct {
ServiceId string `json:"serviceId"`
}
type GpuRequest ¶
type HealthCheck ¶
type HealthCheck struct { TimeoutInSeconds int `json:"timeoutInSeconds,omitempty"` IntervalInSeconds int `json:"intervalInSeconds,omitempty"` UnhealthyThreshold int `json:"unhealthyThreshold,omitempty"` HealthyThreshold int `json:"healthyThreshold,omitempty"` HealthCheckString string `json:"healthCheckString,omitempty"` HealthCheckType string `json:"healthCheckType,omitempty"` }
type ImageDetail ¶
type ImageDetail struct { Id string `json:"id"` ImageId string `json:"imageId"` Name string `json:"name"` NameFri string `json:"nameFri"` ImageType string `json:"imageType"` SnapshotId string `json:"snapshotId"` Cpu int `json:"cpu"` Memory int `json:"memory"` OsType string `json:"osType"` OsVersion string `json:"osVersion"` OsName string `json:"osName"` OsBuild string `json:"osBuild"` OsLang string `json:"osLang"` DiskSize int `json:"diskSize"` CreateTime string `json:"createTime"` Status string `json:"status"` MinMem int `json:"minMem"` MinCpu int `json:"minCpu"` MinDiskGb int `json:"minDiskGb"` Desc string `json:"desc"` OsArch string `json:"osArch"` EphemeralSize int `json:"ephemeralSize"` ImageDescription string `json:"imageDescription"` FpgaType string `json:"fpgaType"` }
type ImageRegistrySecret ¶
type ImageRegistrySecret struct {
Name string `json:"name,omitempty"`
}
type IpInfo ¶
type IpInfo struct { ServiceProvider ServiceProvider `json:"serviceProvider"` Ip string `json:"ip"` Ipv6 string `json:"ipv6"` }
type IpPackageVo ¶
type IpPackageVo struct { PublicIp string `json:"publicIp"` Ipv6PublicIp string `json:"ipv6PublicIp"` InternalIp string `json:"internalIp"` MultiplePublicIp []IpInfo `json:"multiplePublicIp"` ServiceProvider ServiceProvider `json:"serviceProvider"` }
type IpamResultVo ¶
type LbDeployPo ¶
type ListDeploymentArgs ¶
type ListDeploymentArgs struct {
DeploymentID string `json:"deploymentID"`
}
type ListRequest ¶
type ListRequest struct { KeywordType string `json:"keywordType"` Keyword string `json:"keyword"` PageNo int `json:"pageNo,omitempty"` PageSize int `json:"pageSize,omitempty"` Order string `json:"order,omitempty"` OrderBy string `json:"orderBy,omitempty"` Status string `json:"status"` Region string `json:"region"` OsName string `json:"osName"` ServiceId string `json:"serviceId"` }
type ListServiceResult ¶
type ListVmImageArgs ¶
type ListVmImageArgs struct { KeywordType string `json:"keywordType"` Keyword string `json:"keyword"` PageNo int `json:"pageNo,omitempty"` PageSize int `json:"pageSize,omitempty"` Order string `json:"order,omitempty"` OrderBy string `json:"orderBy,omitempty"` Status string `json:"status"` Region string `json:"region"` OsName string `json:"osName"` ServiceId string `json:"serviceId"` Type string `json:"type,omitempty"` }
type ListVmImageResult ¶
type ListVmServiceArgs ¶
type ListVmServiceArgs struct { KeywordType string `json:"keywordType,omitempty"` Keyword string `json:"keyword,omitempty"` PageNo int `json:"pageNo,omitempty"` PageSize int `json:"pageSize,omitempty"` Order string `json:"order,omitempty"` OrderBy string `json:"orderBy,omitempty"` Status string `json:"status,omitempty"` Region string `json:"region,omitempty"` OsName string `json:"osName,omitempty"` ServiceId string `json:"serviceId,omitempty"` }
type ListVmServiceResult ¶
type ListVmServiceResult struct { Orders []OrderModel `json:"orders"` OrderBy string `json:"orderBy"` Order string `json:"order"` PageNo int `json:"pageNo"` PageSize int `json:"pageSize"` TotalCount int `json:"totalCount"` Result []VmServiceBriefVo `json:"result"` }
type Listeners ¶
type Listeners struct { Protocol Protocol `json:"protocol,omitempty"` Port int `json:"port,omitempty"` BackendPort int `json:"backendPort,omitempty"` KeepaliveTimeout int `json:"keepaliveTimeout,omitempty"` Scheduler LbMode `json:"scheduler,omitempty"` EnableCipTTM bool `json:"enableCipTTM,omitempty"` EnableVipTTM bool `json:"enableVipTTM,omitempty"` // health check config HealthCheckInterval int `json:"healthCheckInterval,omitempty"` HealthCheckRetry int `json:"healthCheckRetry,omitempty"` HealthCheckTimeout int `json:"healthCheckTimeout,omitempty"` UdpHealthCheckString string `json:"udpHealthCheckString,omitempty"` HealthCheckType string `json:"healthCheckType,omitempty"` }
type LogCollectDetail ¶
type LogCollectDetail struct { ServiceId string `json:"serviceId,omitempty"` LogCollect bool `json:"logCollect,omitempty"` LogPath string `json:"logPath,omitempty"` JsonAnalysis bool `json:"jsonAnalysis,omitempty"` PushLog bool `json:"pushLog,omitempty"` Standard bool `json:"standard,omitempty"` Custom bool `json:"custom,omitempty"` LogOutputType string `json:"logOutputType,omitempty"` EsIP string `json:"esIP,omitempty"` EsPort int `json:"esPort,omitempty"` EsIndex string `json:"esIndex,omitempty"` Encrypted bool `json:"encrypted,omitempty"` EsUserName string `json:"esUserName,omitempty"` EsUserPassword string `json:"esUserPassword,omitempty"` }
type LogicPageVmInstanceResult ¶
type LogicPageVmInstanceResult struct { Orders []OrderModel `json:"orders"` OrderBy string `json:"orderBy"` Order string `json:"order"` PageNo int `json:"pageNo"` PageSize int `json:"pageSize"` TotalCount int `json:"totalCount"` Result []VmInstanceDetailsVo `json:"result"` }
type MetricsType ¶
type MetricsType string
const ( MetricsTypeCpu MetricsType = "CPU" MetricsTypeMemory MetricsType = "MEMORY" MetricsTypeBandwidthReceive MetricsType = "BANDWIDTH_RECEIVE" MetricsTypeBandwidthTransmit MetricsType = "BANDWIDTH_TRANSMIT" MetricsTypeTrafficReceive MetricsType = "TRAFFIC_RECEIVE" MetricsTypeTrafficTransmit MetricsType = "TRAFFIC_TRANSMIT" MetricsTypeNodeBwReceive MetricsType = "NODE_BW_RECEIVE" MetricsTypeNodeBwTransmit MetricsType = "NODE_BW_TRANSMIT" MetricsTypeNodeLbBwReceive MetricsType = "NODE_LB_BW_RECEIVE" MetricsTypeNodeLbBwTransmit MetricsType = "NODE_LB_BW_TRANSMIT" MetricsTypeRequestNum MetricsType = "REQUEST_NUMBER" MetricsTypeRequestRate MetricsType = "REQUEST_RATE" MetricsTypeRequestDelay MetricsType = "REQUEST_DELAY" MetricsTypeUnknown MetricsType = "UNKNOWN" )
type NetworkConfig ¶
type OperationVo ¶
type OrderModel ¶
type PostHttpReq ¶
type RegionInfo ¶ added in v0.9.72
type ReinstallVmInstanceArg ¶
type ReinstallVmInstanceResult ¶
type ReinstallVmInstanceResult struct { Result bool `json:"result"` Action string `json:"action"` Details VmInstanceBriefVo `json:"details"` }
type ResourceBriefVo ¶
type ResourceBriefVo struct { ServiceId string `json:"serviceId"` ServiceName string `json:"serviceName"` ResourceId string `json:"resourceId"` ResourceName string `json:"resourceName"` Labels map[string]string `json:"labels"` TotalCpu int `json:"totalCpu"` TotalMem int `json:"totalMem"` TotalGpu int `json:"totalGpu"` TotalPods int `json:"totalPods"` RunningPods int `json:"runningPods"` TotalDeploy int `json:"totalDeploy"` IngressBandwidth string `json:"ingressBandwidth"` DeployInstance DeploymentInstance `json:"deployInstance"` ImageList []string `json:"imageList"` Containers []ContainerDetails `json:"containers"` ImageRegistrySecrets []ImageRegistrySecret `json:"imageRegistrySecrets"` }
type ResourceStatus ¶ added in v0.9.72
type ResourceStatus string
type ServiceAction ¶
type ServiceAction string
const ( ServiceActionStart ServiceAction = "start" ServiceActionStop ServiceAction = "stop" )
type ServiceActionResult ¶
type ServiceBatchOperateArgs ¶
type ServiceBatchOperateResult ¶
type ServiceBatchOperateResult struct { Result bool `json:"result"` Action string `json:"action"` Details []OperationVo `json:"details"` }
type ServiceBriefVo ¶
type ServiceBriefVo struct { ServiceId string `json:"serviceId"` ServiceName string `json:"serviceName"` Level string `json:"level"` Status string `json:"status"` TotalCpu int `json:"totalCpu"` TotalMen int `json:"totalMem"` TotalGpu int `json:"totalGpu"` TotalDisk int `json:"totalDisk"` Regions int `json:"regions"` TotalPods int `json:"totalPods"` RunningPods int `json:"runningPods"` TagsMap []Tag `json:"tagMap"` DeployInstances []DeploymentInstance `json:"deployInstances"` CreateTime string `json:"createTime"` LastUpdateTime string `json:"lastUpdateTime"` }
type ServiceDetailsVo ¶
type ServiceDetailsVo struct { ServiceId string `json:"serviceId"` ServiceName string `json:"serviceName"` Status string `json:"status"` TotalCpu int `json:"totalCpu"` TotalMem int `json:"totalMem"` TotalGpu int `json:"totalGpu"` TotalDisk int `json:"totalDisk"` TotalPods int `json:"totalPods"` RunningPods int `json:"runningPods"` RegionSize int `json:"regionSize"` TagsMap []Tag `json:"tagsMap"` DeployInstances []DeploymentInstance `json:"deployInstances"` ResourceBriefVos []ResourceBriefVo `json:"resourceBriefVos"` ImageRegistrySecrets []ImageRegistrySecret `json:"imageRegistrySecrets"` LogCollectDetail LogCollectDetail `json:"logCollectDetail"` CreateTime string `json:"createTime"` LastUpdateTime string `json:"lastUpdateTime"` }
type ServiceMetricsResult ¶
type ServiceProvider ¶
type ServiceProvider string
const ( ServiceChinaMobile ServiceProvider = "CHINA_MOBILE" ServiceChinaUnicom ServiceProvider = "CHINA_UNICOM" ServiceChinaTelecom ServiceProvider = "CHINA_TELECOM" ServiceTripleLine ServiceProvider = "TRIPLE_LINE" )
type ServiceProviderInfo ¶ added in v0.9.72
type ServiceProviderInfo struct { ServiceProvider ServiceProvider `json:"serviceProvider"` Name string `json:"name"` Capability []string `json:"capability"` }
type SystemVolumeConfig ¶
type UpdateBecVmForm ¶
type UpdateBecVmForm struct { Type UpdateVmType `json:"type,omitempty"` Cpu int `json:"cpu,omitempty"` Memory int `json:"memory,omitempty"` NeedRestart bool `json:"needRestart,omitempty"` AdminPass string `json:"adminPass,omitempty"` ImageId string `json:"imageId,omitempty"` Bandwidth int `json:"bandwidth,omitempty"` ImageType ImageType `json:"imageType,omitempty"` VmName string `json:"vmName,omitempty"` DataVolumeList *[]VolumeConfig `json:"dataVolumeList,omitempty"` SystemVolume *SystemVolumeConfig `json:"systemVolume,omitempty"` }
type UpdateBindPodWeightArgs ¶
type UpdateBlbArgs ¶
type UpdateBlbResult ¶
type UpdateBlbResult struct { Result bool `json:"result"` Action string `json:"action"` Details BlbInstanceVo `json:"details"` }
type UpdateServiceArgs ¶
type UpdateServiceArgs struct { Type UpdateServiceType `json:"type,omitempty"` DeployInstances *[]DeploymentInstance `json:"deployInstances,omitempty"` ServiceName string `json:"serviceName,omitempty"` Containers *[]ContainerDetails `json:"containers,omitempty"` ImageRegistrySecrets *[]ImageRegistrySecret `json:"imageRegistrySecrets,omitempty"` Bandwidth float32 `json:"bandwidth,omitempty"` }
type UpdateServiceResult ¶
type UpdateServiceResult struct { Result bool `json:"result"` Action string `json:"action"` Details []ServiceBriefVo `json:"details"` }
type UpdateServiceType ¶
type UpdateServiceType string
const ( UpdateServiceTypeName UpdateServiceType = "NAME" UpdateServiceTypeReplicas UpdateServiceType = "REPLICAS" UpdateServiceTypeNameResource UpdateServiceType = "RESOURCE" )
type UpdateVmDeploymentArgs ¶
type UpdateVmDeploymentArgs struct { Type string `json:"type,omitempty"` Cpu int `json:"cpu,omitempty"` Memory int `json:"memory,omitempty"` NeedRestart bool `json:"needRestart,omitempty"` AdminPass string `json:"adminPass,omitempty"` ImageId string `json:"imageId,omitempty"` Bandwidth int `json:"bandwidth,omitempty"` ImageType ImageType `json:"imageType,omitempty"` VmName string `json:"vmName,omitempty"` DataVolumeList *[]VolumeConfig `json:"dataVolumeList,omitempty"` SystemVolume *SystemVolumeConfig `json:"systemVolume,omitempty"` KeyConfig *KeyConfig `json:"keyConfig,omitempty"` }
type UpdateVmDeploymentResult ¶
type UpdateVmDeploymentResult struct { Result bool `json:"result"` Action string `json:"action"` Details VmInstanceBriefVo `json:"details"` }
type UpdateVmImageArgs ¶
type UpdateVmImageArgs struct {
Name string `json:"name,omitempty"`
}
type UpdateVmServiceArgs ¶
type UpdateVmServiceArgs struct { UpdateBecVmForm ServiceName string `json:"serviceName,omitempty"` DeployInstances *[]DeploymentInstance `json:"deployInstances,omitempty"` }
type UpdateVmServiceResult ¶
type UpdateVmServiceResult struct { Details VmServiceBriefVo `json:"details"` Result bool `json:"result"` Action string `json:"action"` }
type UpdateVmType ¶
type UpdateVmType string
const ( UpdateVmTypeServiceName UpdateVmType = "serviceName" UpdateVmTypeVmName UpdateVmType = "vmName" UpdateVmPassWord UpdateVmType = "password" UpdateVmReplicas UpdateVmType = "replicas" UpdateVmResource UpdateVmType = "resource" )
type V1ConfigMapKeySelector ¶
type V1ContainerPort ¶
type V1EnvVar ¶
type V1EnvVar struct { Name string `json:"name,omitempty"` Value string `json:"value,omitempty"` ValueFrom *V1EnvVarSource `json:"valueFrom,omitempty"` }
type V1EnvVarSource ¶
type V1EnvVarSource struct { ConfigMapKeyRef *V1ConfigMapKeySelector `json:"configMapKeyRef,omitempty"` FieldRef *V1ObjectFieldSelector `json:"fieldRef,omitempty"` ResourceFieldRef *V1ResourceFieldSelector `json:"resourceFieldRef,omitempty"` SecretKeyRef *V1SecretKeySelector `json:"secretKeyRef,omitempty"` }
type V1ObjectFieldSelector ¶
type V1ResourceFieldSelector ¶
type V1SecretKeySelector ¶
type V1VolumeMount ¶
type VmConfigResult ¶
type VmConfigResult struct { Cpu int `json:"cpu"` Mem int `json:"mem"` Region Region `json:"region"` ServiceProvider ServiceProvider `json:"serviceProvider"` City string `json:"city"` NeedPublicIp bool `json:"needPublicIp"` Bandwidth string `json:"bandwidth"` OsImage ImageDetail `json:"osImage"` DataVolumeList []VolumeConfig `json:"dataVolumeList"` SystemVolume SystemVolumeConfig `json:"systemVolume"` }
type VmImageOperateResult ¶
type VmImageVo ¶
type VmImageVo struct { ImageId string `json:"imageId"` Status string `json:"status"` BccImageId string `json:"bccImageId"` Name string `json:"name"` AccountId string `json:"accountId"` ImageType string `json:"imageType"` SystemDisk int `json:"systemDisk"` OsType string `json:"osType"` OsVersion string `json:"osVersion"` OsName string `json:"osName"` OsBuild string `json:"osBuild"` OsLang string `json:"osLang"` OsArch string `json:"osArch"` CreateTime string `json:"createTime"` UpdateTime string `json:"updateTime"` }
type VmInstanceBatchOperateAction ¶
type VmInstanceBatchOperateAction string
const ( VmInstanceBatchOperateStart VmInstanceBatchOperateAction = "start" VmInstanceBatchOperateStop VmInstanceBatchOperateAction = "stop" VmInstanceBatchOperateRestart VmInstanceBatchOperateAction = "restart" )
type VmInstanceBriefVo ¶
type VmInstanceBriefVo struct { IpPackageVo VmId string `json:"vmId"` Uuid string `json:"uuid"` VmName string `json:"vmName"` Status string `json:"status"` Cpu int `json:"cpu"` Mem int `json:"mem"` Gpu int `json:"gpu"` Region Region `json:"region"` City string `json:"city"` NeedPublicIp bool `json:"needPublicIp"` NeedIpv6PublicIp bool `json:"needIpv6PublicIp"` Bandwidth string `json:"bandwidth"` OsImage ImageDetail `json:"osImage"` ServiceId string `json:"serviceId"` CreateTime string `json:"createTime"` }
type VmInstanceDetailsVo ¶
type VmInstanceDetailsVo struct { VmInstanceBriefVo RootDiskSize int `json:"rootDiskSize"` DataStorage int `json:"dataStorage"` DataVolumeList []VolumeConfig `json:"dataVolumeList"` SystemVolume SystemVolumeConfig `json:"systemVolume"` RackId string `json:"rackId,omitempty"` HostId string `json:"hostId,omitempty"` SwitchId string `json:"switchId"` PrivateIps []string `json:"privateIps"` }
type VmInstanceIdVo ¶ added in v0.9.72
type VmPrivateIpResult ¶
type VmPrivateIpResult struct { Result IpamResultVo `json:"result"` Success bool `json:"success"` }
type VmServiceAction ¶
type VmServiceAction string
const ( VmServiceActionStart VmServiceAction = "start" VmServiceActionStop VmServiceAction = "stop" )
type VmServiceActionResult ¶
type VmServiceBatchAction ¶
type VmServiceBatchAction string
const ( VmServiceBatchStart VmServiceBatchAction = "start" VmServiceBatchStop VmServiceBatchAction = "stop" )
type VmServiceBatchActionArgs ¶
type VmServiceBatchActionArgs struct { IdList []string `json:"idList,omitempty"` Action VmServiceBatchAction `json:"action,omitempty"` }
type VmServiceBatchActionResult ¶
type VmServiceBatchActionResult struct { Result bool `json:"result"` Action string `json:"action"` Details []OperationVo `json:"details"` }
type VmServiceBriefVo ¶
type VmServiceBriefVo struct { ServiceId string `json:"serviceId"` ServiceName string `json:"serviceName"` Status ResourceStatus `json:"status"` TotalCpu int `json:"totalCpu"` TotalMem int `json:"totalMem"` TotalDisk int `json:"totalDisk"` TotalRootDisk int `json:"totalRootDisk"` Regions int `json:"regions"` DeployInstances []DeploymentInstance `json:"deployInstances"` TotalInstances int `json:"totalInstances"` RunningInstances int `json:"runningInstances"` OsImage ImageDetail `json:"osImage"` CreateTime string `json:"createTime"` TotalGpu int `json:"totalGpu"` Instances []VmInstanceIdVo `json:"instances"` }
type VmServiceDetailsVo ¶
type VmServiceDetailsVo struct { VmServiceBriefVo Bandwidth string `json:"bandwidth"` TotalBandwidth string `json:"totalBandwidth"` DataVolumeList []VolumeConfig `json:"dataVolumeList"` SystemVolumeList []VolumeConfig `json:"systemVolumeList"` }
type Volume ¶
type Volume struct { EmptyDir *[]EmptyDir `json:"emptyDir,omitempty"` ConfigMap *[]ConfigFile `json:"configMap,omitempty"` Secret *[]Secret `json:"secret,omitempty"` VolumeClaimTemplates *[]VolumeClaimTemplates `json:"volumeClaimTemplates,omitempty"` }
type VolumeClaimTemplates ¶
Click to show internal directories.
Click to hide internal directories.