Documentation ¶
Index ¶
Constants ¶
View Source
const ( InstrRecStatusRunning = "RUNNING" InstrRecStatusSucc = "SUCC" InstrRecStatusFail = "FAIL" )
View Source
const ( TaskStatusInit = "INIT" TaskStatusRunning = "RUNNING" TaskStatusSuccess = "SUCC" TaskStatusFail = "FAIL" )
View Source
const ( //扩容 TaskExpand = "expand" //缩容 TaskShrink = "shrink" )
View Source
const ( TaskStepInit = "INIT" TaskStepBridgxExpandInit = "BRIDGX_EXPAND_INIT" TaskStepBridgxShrinkInit = "BRIDGX_SHRINK_INIT" TaskStepBridgxExpandSucc = "BRIDGX_EXPAND_SUCC" TaskStepBridgxShrinkSucc = "BRIDGX_SHRINK_SUCC" TaskStepBaseEnvInit = "BASE_ENV_INIT" TaskStepBaseEnvSucc = "BASE_ENV_SUCC" TaskStepSvcEnvInit = "SVC_ENV_INIT" TaskStepSvcEnvSucc = "SVC_ENV_SUCC" TaskStepMountInit = "MOUNT_INIT" TaskStepUmountInit = "UMOUNT_INIT" TaskStepMountSucc = "MOUNT_SUCC" TaskStepUmountSucc = "UMOUNT_SUCC" )
View Source
const ( NodeactTaskId = "nodeact_task_id" BridgXTaskId = "bridgx_task_id" )
View Source
const ( MountValueALB = "slb" MountValueNginx = "nginx" )
View Source
const ( ENVInt = "nodeact.initbase" //环境初始化 SERVICEInt = "nodeact.initsvc" // 服务初始化 MountTypeSLB = "mount.slb" //挂载slb )
Variables ¶
View Source
var TaskStatusDesc = func(TaskStep string) string { if v, ok := TaskStatusDescMap[TaskStep]; ok { return v } return "UnKnown" }
View Source
var TaskStatusDescMap = map[string]string{ TaskStatusInit: "已创建", TaskStatusRunning: "进行中", TaskStatusSuccess: "成功", TaskStatusFail: "失败", }
View Source
var TaskStepDesc = func(TaskStep string) string { if v, ok := TaskStepDescMap[TaskStep]; ok { return v } return "UnKnown" }
View Source
var TaskStepDescMap = map[string]string{ TaskStepInit: "待执行", TaskStepBridgxExpandInit: "计算资源扩容", TaskStepBridgxShrinkInit: "计算资源缩容", TaskStepBridgxExpandSucc: "计算资源已获取", TaskStepBridgxShrinkSucc: "计算资源已缩容", TaskStepBaseEnvInit: "基础环境搭建", TaskStepBaseEnvSucc: "基础环境搭建成功", TaskStepSvcEnvInit: "服务搭建", TaskStepSvcEnvSucc: "服务搭建成功", TaskStepMountInit: "执行实例挂载", TaskStepUmountInit: "执行实例卸载", TaskStepMountSucc: "实例挂载成功", TaskStepUmountSucc: "实例卸载成功", }
Functions ¶
This section is empty.
Types ¶
type InstInfoResp ¶ added in v0.1.1
type InstInfoResp struct { InstanceId string `json:"instance_id"` IpInner string `json:"ip_inner"` IpOuter string `json:"ip_outer"` Status InstanceStatus `json:"instance_status"` }
type Instance ¶
type Instance struct { InstanceId string `json:"instance_id"` IpInner string `json:"ip_inner"` IpOuter string `json:"ip_outer"` CreateAt string `json:"create_at"` Status InstanceStatus `json:"status"` }
type InstanceAuth ¶
type InstanceInfo ¶
type InstanceMeta ¶
type InstanceMeta struct { TaskId int64 `json:"task_id"` InstanceId string `json:"instance_id"` InstanceStatus InstanceStatus `json:"instance_status"` }
type InstanceStatus ¶
type InstanceStatus string
var ( InstanceStatusInit InstanceStatus = "INIT" //初始 InstanceStatusBase InstanceStatus = "BASE" // base 环境已完成 InstanceStatusSvc InstanceStatus = "SVC" // service 环境已完成 InstanceStatusALB InstanceStatus = "ALB" // 后端挂载alb InstanceStatusUNALB InstanceStatus = "UNALB" // 后端卸载alb InstanceStatusFail InstanceStatus = "FAIL" // 异常、失败 InstanceStatusDeleted InstanceStatus = "DELETED" // 已缩容 )
type ParamsMount ¶
type ParamsServiceEnv ¶
type ParamsServiceEnv struct { ImageStorageType string `json:"image_storage_type"` ImageUrl string `json:"image_url"` ServiceName string `json:"service_name"` Port int64 `json:"port"` Account string `json:"account"` Password string `json:"password"` }
ParamsServiceEnv ImageInfo 镜像信息
type RelationTaskId ¶ added in v0.2.0
type ServiceEnv ¶
type ServiceInfo ¶
type TaskDescribe ¶
Click to show internal directories.
Click to hide internal directories.