Documentation ¶
Index ¶
- Constants
- func InstanceAfterDeploy(ctx context.Context, deployInfo *types.DeployInfo, tmplId int64, db *gorm.DB) (int64, error)
- func InstanceBeforeDeploy(ctx context.Context, deployInfo *types.DeployInfo, tmplId int64, db *gorm.DB) (int64, error)
- func InstanceBeforeDownload(ctx context.Context, deployInfo *types.DeployInfo, tmplId int64, db *gorm.DB) (int64, error)
- func InstanceDeploy(ctx context.Context, deployInfo *types.DeployInfo, tmplId int64, db *gorm.DB) (int64, error)
- func InstanceDownloadExec(ctx context.Context, deployInfo *types.DeployInfo, tmplId int64, db *gorm.DB) (int64, error)
- func IsAlibabaCloudAccountValid(account config.AlibabaCloudAccount) bool
- func RemoteCmdExec(ctx context.Context, localCmd string, remoteScript string, ...) ([]byte, error)
- type ActionSvc
- type BaseEnvInitAsyncSvcReq
- type BridgXSvc
- type BridgXSvcReq
- type BridgXSvcResp
- type CallBackNodeInitSvcReq
- type ClusterInstanceCount
- type ClusterListResp
- type DeployAsyncReq
- type EnvService
- func (s *EnvService) AfterDeployAsync(ctx context.Context, svcReq *DeployAsyncReq) error
- func (s *EnvService) BaseEnvInitAsync(ctx context.Context, svcReq *BaseEnvInitAsyncSvcReq) error
- func (s *EnvService) BaseEnvInitSingle(ctx context.Context, taskId int64, inst *types.InstanceInfo, ...) error
- func (s *EnvService) BeforeDeployAsync(ctx context.Context, svcReq *DeployAsyncReq) error
- func (s *EnvService) CallBackSvc(ctx context.Context, taskId int64, instId string, ...) error
- func (s *EnvService) DeployAsync(ctx context.Context, svcReq *DeployAsyncReq) error
- func (s *EnvService) DeployBeforeDownloadInitAsync(ctx context.Context, svcReq *BaseEnvInitAsyncSvcReq) error
- func (s *EnvService) DeployBeforeDownloadInitSingle(ctx context.Context, taskId int64, cmd string, inst *types.InstanceInfo, ...) error
- func (s *EnvService) DeployDownloadAsync(ctx context.Context, svcReq *DeployAsyncReq) error
- func (s *EnvService) ExecCmdWithUpdateInstanceStatus(ctx context.Context, taskId int64, cmd string, inst *types.InstanceInfo, ...) error
- func (s *EnvService) IsNotHttpOk(res []byte) bool
- func (s *EnvService) IsNotRemoteCmdOk(res []byte) bool
- func (s *EnvService) NodeUpdateDeploy(ctx context.Context, instanceList []*types.InstanceInfo, ...) error
- func (s *EnvService) NodeUpdateStore(ctx context.Context, instanceList []*types.InstanceInfo, ...) error
- func (s *EnvService) ServiceEnvInitAsync(ctx context.Context, svcReq *SvcEnvInitAsyncSvcReq) error
- func (s *EnvService) ServiceEnvInitSingle(ctx context.Context, taskId int64, inst *types.InstanceInfo, ...) error
- type ExposeMountSvcReq
- type ExposeMountSvcResp
- type ExposeUmountSvcReq
- type ExposeUmountSvcResp
- type GetServiceByIpResponse
- type InitServicSvcReq
- type InstanceCountResp
- type InstanceService
- type InstrSvc
- func (s *InstrSvc) CreateBaseEnvInstr(ctx context.Context, args *types.BaseEnv, tmpId int64, needReverse bool, ...) (int64, int64, error)
- func (s *InstrSvc) CreateBridgxExpandInstr(ctx context.Context, tmplId int64, revTmplId int64, needReverse bool, ...) (int64, int64, error)
- func (s *InstrSvc) CreateBridgxShrinkInstr(ctx context.Context, tmplId int64, dbo *gorm.DB) (int64, error)
- func (s *InstrSvc) CreateInstanceAfterDeploy(ctx context.Context, args *types.DeployInfo, tmpId int64, dbo *gorm.DB) (int64, error)
- func (s *InstrSvc) CreateInstanceBeforeDeploy(ctx context.Context, args *types.DeployInfo, tmpId int64, dbo *gorm.DB) (int64, error)
- func (s *InstrSvc) CreateInstanceBeforeDownload(ctx context.Context, args *types.DeployInfo, tmpId int64, dbo *gorm.DB) (int64, error)
- func (s *InstrSvc) CreateInstanceDeploy(ctx context.Context, args *types.DeployInfo, tmpId int64, dbo *gorm.DB) (int64, error)
- func (s *InstrSvc) CreateInstanceDownloadExec(ctx context.Context, args *types.DeployInfo, tmpId int64, dbo *gorm.DB) (int64, error)
- func (s *InstrSvc) CreateMountSlbInstr(ctx context.Context, args *types.ParamsMount, tmplId, revTmplId int64, ...) (int64, int64, error)
- func (s *InstrSvc) CreateServiceEnvInstr(ctx context.Context, args *types.ServiceEnv, tmplId int64, needReverse bool, ...) (int64, int64, error)
- func (s *InstrSvc) CreateUMountSlbInstr(ctx context.Context, args *types.ParamsMount, tmplId int64, dbo *gorm.DB) (int64, error)
- func (s *InstrSvc) ExecAct(ctx context.Context, args interface{}, act types.Action) (svcResp interface{}, err error)
- type InstrSvcReq
- type InstrSvcResp
- type IntegrationService
- type MountService
- type NodeActSvc
- func (s *NodeActSvc) ExecAct(ctx context.Context, args interface{}, act types.Action) (svcResp interface{}, err error)
- func (s *NodeActSvc) InitBaseAction(ctx context.Context, instGroup *nodeact.InstanceGroup, ...) (*NodeActSvcResp, error)
- func (s *NodeActSvc) InitServiceAction(ctx context.Context, instGroup *nodeact.InstanceGroup, ...) (*NodeActSvcResp, error)
- func (s *NodeActSvc) MountInstAction(ctx context.Context, instGroup *nodeact.InstanceGroup, ...) (*ExposeMountSvcResp, error)
- func (s *NodeActSvc) PollQueryBaseNode(ctx context.Context, taskId int64) (*NodeActSvcResp, error)
- func (s *NodeActSvc) PoolQueryServiceNode(ctx context.Context, taskId int64) (*NodeActSvcResp, error)
- func (s *NodeActSvc) RatePass(rate string) bool
- func (s *NodeActSvc) UmountInstAction(ctx context.Context, taskId, serviceClusterId int64, ...) (*ExposeUmountSvcResp, error)
- type NodeActSvcReq
- type NodeActSvcResp
- type NodeService
- type ScheduleSvc
- type ScheduleSvcReq
- type ScheduleSvcResp
- type ServiceClusterInfo
- type ServiceCreateSvcRequest
- type ServiceCreateSvcResponse
- type ServiceDeploySvcReq
- type ServiceDeploySvcResp
- type ServiceExpandSvcReq
- type ServiceExpandSvcResp
- type ServiceShrinkSvcReq
- type ServiceShrinkSvcResp
- type ServiceSvc
- func (s *ServiceSvc) CreateService(ctx context.Context, svcReq *ServiceCreateSvcRequest) (*ServiceCreateSvcResponse, error)
- func (s *ServiceSvc) Delete(ctx context.Context, ids []int64) error
- func (s *ServiceSvc) Detail(ctx context.Context, serviceName string) (map[string]interface{}, error)
- func (s *ServiceSvc) GetExpandHistory(ctx context.Context, page, pageSize, serviceClusterId int) (map[string]interface{}, error)
- func (s *ServiceSvc) GetServiceClusterList(ctx context.Context, serviceName string) (*ClusterListResp, error)
- func (s *ServiceSvc) GetServiceList(ctx context.Context, page, pageSize int, serviceName, lang string) (map[string]interface{}, error)
- func (s *ServiceSvc) Update(ctx context.Context, serviceName, description, domain, port, gitRepo string) (map[string]interface{}, error)
- type SvcEnvInitAsyncSvcReq
- type TaskDeployInfo
- type TaskDescribeSvcReq
- type TaskDescribeSvcResp
- type TaskDetail
- type TaskInfoSvcReq
- type TaskInfoSvcResp
- type TaskInstancesSvcReq
- type TaskInstancesSvcResp
- type TaskService
- func (s *TaskService) Describe(ctx context.Context, svcReq *TaskDescribeSvcReq) (*TaskDescribeSvcResp, error)
- func (s *TaskService) GetRunningTask(ctx context.Context, serviceClusterId, taskId int64) (*TaskDetail, error)
- func (s *TaskService) HasRunningTask(ctx context.Context, serviceName, clusterName string) (bool, error)
- func (s *TaskService) Info(ctx context.Context, svcReq *TaskInfoSvcReq) (*TaskInfoSvcResp, error)
- func (s *TaskService) InstanceList(ctx context.Context, page, pageSize int, taskId int64, ...) (int64, []types.InstInfoResp, error)
- func (s *TaskService) Instances(ctx context.Context, svcReq *TaskInstancesSvcReq) (*TaskInstancesSvcResp, error)
- type TemplateSvc
- func (s *TemplateSvc) Delete(ctx context.Context, tmpExpandIds []int64) (int64, error)
- func (s *TemplateSvc) ExecAct(ctx context.Context, args interface{}, act types.Action) (svcResp interface{}, err error)
- func (s *TemplateSvc) InfoAction(ctx context.Context, svcReq *TmplInfoSvcReq) (*TemplateSvcResp, error)
- func (s *TemplateSvc) List(ctx context.Context, serviceName string, page, pageSize, serviceClusterId int) (map[string]interface{}, error)
- func (s *TemplateSvc) ListDeployTemplates(ctx context.Context, serviceName string, page, pageSize, serviceClusterId int) (map[string]interface{}, error)
- func (s *TemplateSvc) UpdateAction(ctx context.Context, svcReq *TmplUpdateSvcReq) (*TemplateSvcResp, error)
- func (s *TemplateSvc) UpdateContainerTemplate(ctx context.Context, svcReq *TmplUpdateSvcReq) (*TemplateSvcResp, error)
- func (s *TemplateSvc) UpdateInstanceTemplate(ctx context.Context, svcReq *TmplUpdateSvcReq) (*TemplateSvcResp, error)
- type TemplateSvcReq
- type TemplateSvcResp
- type TmplDeployReq
- type TmplExpandSvcReq
- type TmplExpandSvcResp
- type TmplInfoSvcReq
- type TmplInfoSvcResp
- type TmplUpdateSvcReq
- type TmplUpdateSvcResp
- type UmountSlbSvcReq
- type ZadigResp
- type ZadigSvc
Constants ¶
View Source
const ( ExpandStepTmplInfo = "tmpl_info" ExpandStepBaseEnv = "base_env" ExpandStepServiceEnv = "service_env" ExpandStepMount = "mount" InstanceDeployStepBeforeDownload = "base_env" InstanceDeployStepDownloadExec = "download_exec" InstanceDeployStepBeforeDeploy = "before_deploy" InstanceDeployStepDeploy = "deploy" InstanceDeployStepAfterDeploy = "after_deploy" )
Variables ¶
This section is empty.
Functions ¶
func InstanceAfterDeploy ¶ added in v0.3.0
func InstanceBeforeDeploy ¶ added in v0.3.0
func InstanceBeforeDownload ¶ added in v0.3.0
func InstanceDeploy ¶ added in v0.3.0
func InstanceDownloadExec ¶ added in v0.3.0
func IsAlibabaCloudAccountValid ¶ added in v0.1.1
func IsAlibabaCloudAccountValid(account config.AlibabaCloudAccount) bool
Types ¶
type BaseEnvInitAsyncSvcReq ¶
type BaseEnvInitAsyncSvcReq struct { ServiceClusterId int64 `json:"service_cluster_id"` TaskId int64 `json:"task_id"` Cmd string `json:"cmd"` InstanceList []*types.InstanceInfo `json:"instance_list"` Auth *types.InstanceAuth `json:"auth"` }
type BridgXSvc ¶
type BridgXSvc struct { Expand types.Action PoolQueryExpand types.Action Shrink types.Action PoolQueryShrink types.Action GetCluster types.Action }
func GetBridgXSvcInst ¶
func GetBridgXSvcInst() *BridgXSvc
type BridgXSvcReq ¶
type BridgXSvcReq struct { Count int64 ClusterName string TaskId int64 InstGroup *nodeact.InstanceGroup }
type BridgXSvcResp ¶
type BridgXSvcResp struct { TaskId int64 InstGroup *nodeact.InstanceGroup Auth *types.InstanceAuth }
type CallBackNodeInitSvcReq ¶
type CallBackNodeInitSvcReq struct { Instance *types.InstanceMeta `json:"instance"` Msg string `json:"msg"` }
type ClusterInstanceCount ¶ added in v0.2.0
type ClusterListResp ¶ added in v0.2.0
type ClusterListResp struct {
ClusterList []ServiceClusterInfo `json:"cluster_list"`
}
type DeployAsyncReq ¶ added in v0.3.0
type DeployAsyncReq struct { ServiceClusterId int64 `json:"service_cluster_id"` TaskId int64 `json:"task_id"` Cmd string `json:"cmd"` InstanceList []*types.InstanceInfo `json:"instance_list"` Auth *types.InstanceAuth `json:"auth"` }
type EnvService ¶
type EnvService struct { }
func GetEnvOpsSvcInst ¶
func GetEnvOpsSvcInst() *EnvService
func (*EnvService) AfterDeployAsync ¶ added in v0.3.0
func (s *EnvService) AfterDeployAsync(ctx context.Context, svcReq *DeployAsyncReq) error
func (*EnvService) BaseEnvInitAsync ¶
func (s *EnvService) BaseEnvInitAsync(ctx context.Context, svcReq *BaseEnvInitAsyncSvcReq) error
func (*EnvService) BaseEnvInitSingle ¶
func (s *EnvService) BaseEnvInitSingle(ctx context.Context, taskId int64, inst *types.InstanceInfo, auth *types.InstanceAuth) error
func (*EnvService) BeforeDeployAsync ¶ added in v0.3.0
func (s *EnvService) BeforeDeployAsync(ctx context.Context, svcReq *DeployAsyncReq) error
func (*EnvService) CallBackSvc ¶
func (s *EnvService) CallBackSvc(ctx context.Context, taskId int64, instId string, instStatus types.InstanceStatus, msg string) error
func (*EnvService) DeployAsync ¶ added in v0.3.0
func (s *EnvService) DeployAsync(ctx context.Context, svcReq *DeployAsyncReq) error
func (*EnvService) DeployBeforeDownloadInitAsync ¶ added in v0.3.0
func (s *EnvService) DeployBeforeDownloadInitAsync(ctx context.Context, svcReq *BaseEnvInitAsyncSvcReq) error
func (*EnvService) DeployBeforeDownloadInitSingle ¶ added in v0.3.0
func (s *EnvService) DeployBeforeDownloadInitSingle(ctx context.Context, taskId int64, cmd string, inst *types.InstanceInfo, auth *types.InstanceAuth) error
func (*EnvService) DeployDownloadAsync ¶ added in v0.3.0
func (s *EnvService) DeployDownloadAsync(ctx context.Context, svcReq *DeployAsyncReq) error
func (*EnvService) ExecCmdWithUpdateInstanceStatus ¶ added in v0.3.0
func (s *EnvService) ExecCmdWithUpdateInstanceStatus(ctx context.Context, taskId int64, cmd string, inst *types.InstanceInfo, auth *types.InstanceAuth, instanceStatus types.InstanceStatus) error
func (*EnvService) IsNotHttpOk ¶
func (s *EnvService) IsNotHttpOk(res []byte) bool
func (*EnvService) IsNotRemoteCmdOk ¶
func (s *EnvService) IsNotRemoteCmdOk(res []byte) bool
func (*EnvService) NodeUpdateDeploy ¶ added in v0.3.0
func (s *EnvService) NodeUpdateDeploy(ctx context.Context, instanceList []*types.InstanceInfo, taskId, serviceClusterId int64) error
func (*EnvService) NodeUpdateStore ¶
func (s *EnvService) NodeUpdateStore(ctx context.Context, instanceList []*types.InstanceInfo, taskId, serviceClusterId int64) error
func (*EnvService) ServiceEnvInitAsync ¶
func (s *EnvService) ServiceEnvInitAsync(ctx context.Context, svcReq *SvcEnvInitAsyncSvcReq) error
func (*EnvService) ServiceEnvInitSingle ¶
func (s *EnvService) ServiceEnvInitSingle(ctx context.Context, taskId int64, inst *types.InstanceInfo, auth *types.InstanceAuth, params *types.ParamsServiceEnv, cmd string) error
type ExposeMountSvcReq ¶
type ExposeMountSvcReq struct { TaskId int64 `json:"task_id"` InstanceList []*types.InstanceInfo `json:"instance_list"` MountType string `json:"mount_type"` MountValue string `json:"mount_value"` }
type ExposeMountSvcResp ¶
type ExposeMountSvcResp struct { TaskId int64 `json:"task_id"` InstanceList []*types.InstanceInfo `json:"instance_list"` }
type ExposeUmountSvcReq ¶
type ExposeUmountSvcResp ¶
type ExposeUmountSvcResp struct { TaskId int64 `json:"task_id"` InstanceList []*types.InstanceInfo `json:"instance_list"` }
type GetServiceByIpResponse ¶ added in v0.3.0
type InitServicSvcReq ¶
type InitServicSvcReq struct { Cmd string Params *types.ParamsServiceEnv }
type InstanceCountResp ¶ added in v0.2.0
type InstanceCountResp struct {
ServiceClusterList []ClusterInstanceCount `json:"service_cluster_list"`
}
type InstanceService ¶ added in v0.2.0
type InstanceService struct { }
func GetInstanceService ¶ added in v0.2.0
func GetInstanceService() *InstanceService
func (*InstanceService) GetServiceByIp ¶ added in v0.3.0
func (s *InstanceService) GetServiceByIp(ctx context.Context, ip string) (*GetServiceByIpResponse, error)
func (*InstanceService) InstanceCountByCluster ¶ added in v0.2.0
func (s *InstanceService) InstanceCountByCluster(ctx context.Context, serviceName, serviceClusterName string, clusterId int64) (*InstanceCountResp, error)
type InstrSvc ¶
type InstrSvc struct { BridgXExpand types.Action BridgXShrink types.Action NodeActInitBase types.Action NodeActInitSvc types.Action MountSLB types.Action UmountSLB types.Action MountNginx types.Action UmountNginx types.Action NodeActBeforeDownload types.Action //before download NodeActDownload types.Action //download executable file NodeActBeforeDeploy types.Action //before deploy NodeActDeploy types.Action //deploy NodeActAfterDeploy types.Action //after deploy }
func GetInstrSvcInst ¶
func GetInstrSvcInst() *InstrSvc
func (*InstrSvc) CreateBaseEnvInstr ¶
func (*InstrSvc) CreateBridgxExpandInstr ¶
func (*InstrSvc) CreateBridgxShrinkInstr ¶
func (*InstrSvc) CreateInstanceAfterDeploy ¶ added in v0.3.0
func (*InstrSvc) CreateInstanceBeforeDeploy ¶ added in v0.3.0
func (*InstrSvc) CreateInstanceBeforeDownload ¶ added in v0.3.0
func (*InstrSvc) CreateInstanceDeploy ¶ added in v0.3.0
func (*InstrSvc) CreateInstanceDownloadExec ¶ added in v0.3.0
func (*InstrSvc) CreateMountSlbInstr ¶
func (*InstrSvc) CreateServiceEnvInstr ¶
func (*InstrSvc) CreateUMountSlbInstr ¶
type InstrSvcReq ¶
type InstrSvcReq struct { ServiceName string ServiceClusterId int64 ScheduleTaskId int64 InstrId int64 Instruction *db.Instruction BridgXSvcReq *BridgXSvcReq NodeActSvcReq *NodeActSvcReq }
type InstrSvcResp ¶
type InstrSvcResp struct { BridgXSvcResp *BridgXSvcResp NodeActSvcResp *NodeActSvcResp }
type IntegrationService ¶ added in v0.3.0
type IntegrationService struct { ZadigToken string HttpClient *resty.Client }
func GetIntegrationService ¶ added in v0.3.0
func GetIntegrationService() *IntegrationService
func (*IntegrationService) GetZadigHost ¶ added in v0.3.0
func (s *IntegrationService) GetZadigHost(ctx context.Context) string
func (*IntegrationService) GetZadigToken ¶ added in v0.3.0
func (s *IntegrationService) GetZadigToken() string
type MountService ¶
type MountService struct { }
func GetMountSvcInst ¶
func GetMountSvcInst() *MountService
func (*MountService) Mount ¶
func (mou *MountService) Mount(ctx context.Context, svcReq *ExposeMountSvcReq) (*ExposeMountSvcResp, error)
func (*MountService) Umount ¶
func (mou *MountService) Umount(ctx context.Context, svcReq *ExposeUmountSvcReq) (*ExposeUmountSvcResp, error)
type NodeActSvc ¶
type NodeActSvc struct { InitBase types.Action InitService types.Action MountSlb types.Action UmountSlb types.Action PollQueryInitBase types.Action PollQueryInitService types.Action }
func GetNodeActSvcInst ¶
func GetNodeActSvcInst() *NodeActSvc
func (*NodeActSvc) InitBaseAction ¶
func (s *NodeActSvc) InitBaseAction(ctx context.Context, instGroup *nodeact.InstanceGroup, auth *types.InstanceAuth, serviceClusterId int64) (*NodeActSvcResp, error)
func (*NodeActSvc) InitServiceAction ¶
func (s *NodeActSvc) InitServiceAction(ctx context.Context, instGroup *nodeact.InstanceGroup, auth *types.InstanceAuth, svcReq *InitServicSvcReq, serviceClusterId int64) (*NodeActSvcResp, error)
func (*NodeActSvc) MountInstAction ¶
func (s *NodeActSvc) MountInstAction(ctx context.Context, instGroup *nodeact.InstanceGroup, slbMountInfo *nodeact.ParamsMountInfo) (*ExposeMountSvcResp, error)
func (*NodeActSvc) PollQueryBaseNode ¶
func (s *NodeActSvc) PollQueryBaseNode(ctx context.Context, taskId int64) (*NodeActSvcResp, error)
func (*NodeActSvc) PoolQueryServiceNode ¶
func (s *NodeActSvc) PoolQueryServiceNode(ctx context.Context, taskId int64) (*NodeActSvcResp, error)
func (*NodeActSvc) RatePass ¶
func (s *NodeActSvc) RatePass(rate string) bool
func (*NodeActSvc) UmountInstAction ¶
func (s *NodeActSvc) UmountInstAction(ctx context.Context, taskId, serviceClusterId int64, umountSlbSvcReq *UmountSlbSvcReq) (*ExposeUmountSvcResp, error)
type NodeActSvcReq ¶
type NodeActSvcReq struct { InstGroup *nodeact.InstanceGroup TaskId int64 ServiceClusterId int64 DownloadFileUrl string InstanceCount int64 Auth *types.InstanceAuth //HarborRegisterUrl string // harbor 镜像服务地址,用于加入 docker 的配置允许 http 链接 InitServicSvcReq *InitServicSvcReq //Params *nodeact.ParamsServiceEnv SlbMountInfo *nodeact.ParamsMountInfo // 用于挂载 slb 的服务器组 id UmountSlbSvcReq *UmountSlbSvcReq }
type NodeActSvcResp ¶
type NodeActSvcResp struct { InstGroup *nodeact.InstanceGroup Auth *types.InstanceAuth }
type NodeService ¶
type NodeService struct { }
func GetNodeSvcInst ¶
func GetNodeSvcInst() *NodeService
func (*NodeService) UpdateNode ¶
func (s *NodeService) UpdateNode(ctx context.Context, svcReq *CallBackNodeInitSvcReq) error
type ScheduleSvc ¶
func GetScheduleSvcInst ¶
func GetScheduleSvcInst() *ScheduleSvc
type ScheduleSvcReq ¶
type ScheduleSvcReq struct { ServiceExpandSvcReq *ServiceExpandSvcReq ServiceShrinkSvcReq *ServiceShrinkSvcReq ServiceDeploySvcReq *ServiceDeploySvcReq InstrId int64 }
type ScheduleSvcResp ¶
type ScheduleSvcResp struct { ServiceExpandSvcResp *ServiceExpandSvcResp ServiceShrinkSvcResp *ServiceShrinkSvcResp ServiceDeploySvcResp *ServiceDeploySvcResp }
type ServiceClusterInfo ¶ added in v0.2.0
type ServiceClusterInfo struct { ServiceClusterId int64 `json:"service_cluster_id"` ServiceCluster string `json:"service_cluster"` BridgxCluster string `json:"bridgx_cluster"` InstanceCount int64 `json:"instance_count"` InstanceTypeDesc string `json:"instance_type_desc"` Provider string `json:"provider"` ComputingPowerType string `json:"computing_power_type"` ChargeType string `json:"charge_type"` }
type ServiceCreateSvcRequest ¶
type ServiceCreateSvcRequest struct {
ServiceInfo *types.ServiceInfo `json:"service_info"`
}
type ServiceCreateSvcResponse ¶
type ServiceCreateSvcResponse struct {
ServiceClusterId int64 `json:"service_cluster_id"`
}
type ServiceDeploySvcReq ¶ added in v0.3.0
type ServiceDeploySvcResp ¶ added in v0.3.0
type ServiceDeploySvcResp struct {
TaskId int64 `json:"task_id"`
}
type ServiceExpandSvcReq ¶
type ServiceExpandSvcResp ¶ added in v0.1.1
type ServiceExpandSvcResp struct {
TaskId int64 `json:"task_id"`
}
type ServiceShrinkSvcReq ¶
type ServiceShrinkSvcResp ¶ added in v0.1.1
type ServiceShrinkSvcResp struct {
TaskId int64 `json:"task_id"`
}
type ServiceSvc ¶
type ServiceSvc struct { }
func GetServiceIns ¶
func GetServiceIns() *ServiceSvc
func (*ServiceSvc) CreateService ¶
func (s *ServiceSvc) CreateService(ctx context.Context, svcReq *ServiceCreateSvcRequest) (*ServiceCreateSvcResponse, error)
func (*ServiceSvc) Delete ¶ added in v0.3.0
func (s *ServiceSvc) Delete(ctx context.Context, ids []int64) error
func (*ServiceSvc) GetExpandHistory ¶
func (*ServiceSvc) GetServiceClusterList ¶ added in v0.2.0
func (s *ServiceSvc) GetServiceClusterList(ctx context.Context, serviceName string) (*ClusterListResp, error)
func (*ServiceSvc) GetServiceList ¶
type SvcEnvInitAsyncSvcReq ¶
type SvcEnvInitAsyncSvcReq struct { ServiceClusterId int64 `json:"service_cluster_id"` TaskId int64 `json:"task_id"` InstanceList []*types.InstanceInfo `json:"instance_list"` Auth *types.InstanceAuth `json:"auth"` Params *types.ParamsServiceEnv `json:"params"` Cmd string `json:"string"` }
type TaskDeployInfo ¶ added in v0.3.0
type TaskDeployInfo struct {
DownloadFileUrl string `json:"download_file_url"`
}
type TaskDescribeSvcReq ¶
type TaskDescribeSvcReq struct { TaskId int64 `json:"task_id"` InstanceStatus types.InstanceStatus `json:"instance_status"` }
type TaskDescribeSvcResp ¶
type TaskDescribeSvcResp struct {
TaskDescribe *types.TaskDescribe `json:"task_describe"`
}
type TaskDetail ¶ added in v0.3.0
type TaskDetail struct { ServiceName string `json:"service_name"` ClusterName string `json:"cluster_name"` BridgXClusterName string `json:"bridgx_cluster_name"` DeployFileUrl string `json:"deploy_file_url"` Operator string `json:"operator"` CreateTime string `json:"create_time"` RunningTaskId string `json:"running_task_id"` }
type TaskInfoSvcReq ¶ added in v0.1.1
type TaskInfoSvcReq struct {
TaskId int64 `json:"task_id"`
}
type TaskInfoSvcResp ¶ added in v0.1.1
type TaskInstancesSvcReq ¶
type TaskInstancesSvcReq struct { TaskId int64 `json:"task_id"` InstanceStatus types.InstanceStatus `json:"instance_status"` PageNumber int `json:"page_number"` PageSize int `json:"page_size"` }
type TaskInstancesSvcResp ¶
type TaskService ¶
type TaskService struct { }
func GetTaskSvcInst ¶
func GetTaskSvcInst() *TaskService
func (*TaskService) Describe ¶
func (s *TaskService) Describe(ctx context.Context, svcReq *TaskDescribeSvcReq) (*TaskDescribeSvcResp, error)
func (*TaskService) GetRunningTask ¶ added in v0.3.0
func (s *TaskService) GetRunningTask(ctx context.Context, serviceClusterId, taskId int64) (*TaskDetail, error)
func (*TaskService) HasRunningTask ¶ added in v0.2.0
func (*TaskService) Info ¶ added in v0.1.1
func (s *TaskService) Info(ctx context.Context, svcReq *TaskInfoSvcReq) (*TaskInfoSvcResp, error)
func (*TaskService) InstanceList ¶ added in v0.1.1
func (s *TaskService) InstanceList(ctx context.Context, page, pageSize int, taskId int64, taskStatus types.InstanceStatus) (int64, []types.InstInfoResp, error)
func (*TaskService) Instances ¶
func (s *TaskService) Instances(ctx context.Context, svcReq *TaskInstancesSvcReq) (*TaskInstancesSvcResp, error)
type TemplateSvc ¶
func GetTemplateSvcInst ¶
func GetTemplateSvcInst() *TemplateSvc
func (*TemplateSvc) InfoAction ¶
func (s *TemplateSvc) InfoAction(ctx context.Context, svcReq *TmplInfoSvcReq) (*TemplateSvcResp, error)
func (*TemplateSvc) ListDeployTemplates ¶ added in v0.3.0
func (*TemplateSvc) UpdateAction ¶
func (s *TemplateSvc) UpdateAction(ctx context.Context, svcReq *TmplUpdateSvcReq) (*TemplateSvcResp, error)
func (*TemplateSvc) UpdateContainerTemplate ¶ added in v0.3.0
func (s *TemplateSvc) UpdateContainerTemplate(ctx context.Context, svcReq *TmplUpdateSvcReq) (*TemplateSvcResp, error)
func (*TemplateSvc) UpdateInstanceTemplate ¶ added in v0.3.0
func (s *TemplateSvc) UpdateInstanceTemplate(ctx context.Context, svcReq *TmplUpdateSvcReq) (*TemplateSvcResp, error)
type TemplateSvcReq ¶
type TemplateSvcReq struct { TmplExpandSvcReq *TmplExpandSvcReq TmplInfoSvcReq *TmplInfoSvcReq TmplUpdateSvcReq *TmplUpdateSvcReq }
type TemplateSvcResp ¶
type TemplateSvcResp struct { TmplExpandSvcResp *TmplExpandSvcResp TmplInfoSvcResp *TmplInfoSvcResp TmplUpdateSvcResp *TmplUpdateSvcResp }
type TmplDeployReq ¶ added in v0.3.0
type TmplDeployReq struct { TmplInfo *types.TmpInfo `json:"tmpl_info"` DeployInfo *types.DeployInfo `json:"deploy_info"` }
type TmplExpandSvcReq ¶
type TmplExpandSvcReq struct { EndStep string `json:"end_step"` TmplInfo *types.TmpInfo `json:"tmpl_info"` BaseEnv *types.BaseEnv `json:"base_env"` ServiceEnv *types.ServiceEnv `json:"service_env"` DeployInfo *types.DeployInfo `json:"deploy_info"` Mount *types.ParamsMount `json:"mount"` }
type TmplExpandSvcResp ¶
type TmplInfoSvcReq ¶
type TmplInfoSvcReq struct {
TmplExpandId int64 `json:"tmpl_expand_id"`
}
type TmplInfoSvcResp ¶
type TmplInfoSvcResp struct { TmplInfo *types.TmpInfo `json:"tmpl_info"` BaseEnv *types.BaseEnv `json:"base_env"` ServiceEnv *types.ServiceEnv `json:"service_env"` Mount *types.ParamsMount `json:"mount"` DeployInfo *types.DeployInfo `json:"deploy_info"` }
type TmplUpdateSvcReq ¶
type TmplUpdateSvcReq struct { TmplExpandId int64 `json:"tmpl_expand_id"` EndStep string `json:"end_step"` TmplInfo *types.TmpInfo `json:"tmpl_info"` BaseEnv *types.BaseEnv `json:"base_env"` ServiceEnv *types.ServiceEnv `json:"service_env"` Mount *types.ParamsMount `json:"mount"` DeployInfo *types.DeployInfo `json:"deploy_info"` }
type TmplUpdateSvcResp ¶
type TmplUpdateSvcResp struct {
TmplExpandId int64 `json:"tmpl_expand_id"`
}
type UmountSlbSvcReq ¶
type UmountSlbSvcReq struct { UmountInstCnt int64 `json:"umount_inst_cnt"` SlbInfo *nodeact.ParamsMountInfo `json:"slb_info"` }
type ZadigSvc ¶ added in v0.3.0
type ZadigSvc struct { }
func GetZadigSvcInst ¶ added in v0.3.0
func GetZadigSvcInst() *ZadigSvc
func (*ZadigSvc) GetWorkflowTasks ¶ added in v0.3.0
func (*ZadigSvc) GetWorkflows ¶ added in v0.3.0
Click to show internal directories.
Click to hide internal directories.