Documentation ¶
Index ¶
- Constants
- type CdNodeBroker
- func (t *CdNodeBroker) CreateNode(ctx context.Context, ip, remark string, options ...CdNodeOption) error
- func (t *CdNodeBroker) DeleteNode(ctx context.Context, ip string) (bool, error)
- func (t *CdNodeBroker) GetNodeByName(name string) *gojenkins.Node
- func (t *CdNodeBroker) SetDefCdNodeParam(defCdNodeParam *CdNodeParam)
- func (t *CdNodeBroker) UpdateNodeCache(ctx context.Context) error
- type CdNodeOption
- type CdNodeParam
- type CdS3Info
- type CdScript
- type CdScriptParamDef
- type CdServer
- type CdServerOption
- type CdService
- type DefaultCdService
- type DeployResult
Constants ¶
View Source
const ( RUN_STATUS_RUNNING = 1 RUN_STATUS_FINISH = 2 RUN_STATUS_ERR = 3 )
View Source
const DefaultTaskScript = `` /* 1415-byte string literal not displayed */
View Source
const DefaultXmlTpl = `` /* 1332-byte string literal not displayed */
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CdNodeBroker ¶
type CdNodeBroker struct {
// contains filtered or unexported fields
}
func NewCdNodeBroker ¶
func NewCdNodeBroker(jenkins *gojenkins.Jenkins, env string, nodeParam *CdNodeParam) *CdNodeBroker
func (*CdNodeBroker) CreateNode ¶
func (t *CdNodeBroker) CreateNode(ctx context.Context, ip, remark string, options ...CdNodeOption) error
最好使用内网IP
func (*CdNodeBroker) DeleteNode ¶
func (*CdNodeBroker) GetNodeByName ¶ added in v1.1.0
func (t *CdNodeBroker) GetNodeByName(name string) *gojenkins.Node
func (*CdNodeBroker) SetDefCdNodeParam ¶
func (t *CdNodeBroker) SetDefCdNodeParam(defCdNodeParam *CdNodeParam)
func (*CdNodeBroker) UpdateNodeCache ¶ added in v1.1.0
func (t *CdNodeBroker) UpdateNodeCache(ctx context.Context) error
type CdNodeOption ¶
type CdNodeOption func(*CdNodeParam)
func CdNodeCredIdOption ¶
func CdNodeCredIdOption(credId string) CdNodeOption
func CdNodeJvmOption ¶
func CdNodeJvmOption(jvm string) CdNodeOption
func CdNodeNumExecutorsOption ¶
func CdNodeNumExecutorsOption(numExecutors int) CdNodeOption
func CdNodeRemoteFsOption ¶
func CdNodeRemoteFsOption(remoteFs string) CdNodeOption
func CdNodeSshPortOption ¶
func CdNodeSshPortOption(sshPort string) CdNodeOption
type CdNodeParam ¶
type CdNodeParam struct {
// contains filtered or unexported fields
}
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
func NewCdNodeParam ¶
func NewCdNodeParam(options ...CdNodeOption) *CdNodeParam
type CdS3Info ¶
type CdS3Info struct {
// contains filtered or unexported fields
}
func NewCdS3Info ¶
type CdScript ¶
type CdScript struct {
// contains filtered or unexported fields
}
func NewCdScript ¶
func NewCdScript(scriptParamDefs []*CdScriptParamDef, scriptXmlTpl, scriptContent string, scriptVersion int) *CdScript
func NewDefaultCdScript ¶
func NewDefaultCdScript() *CdScript
type CdScriptParamDef ¶
type CdServer ¶
type CdServer struct {
// contains filtered or unexported fields
}
func NewCdServer ¶
func NewCdServer(ctx context.Context, url, username, token, env string, options ...CdServerOption) *CdServer
func (*CdServer) DeploySimple ¶
func (*CdServer) GetDeployResult ¶
func (*CdServer) GetNodeBroker ¶
func (j *CdServer) GetNodeBroker() *CdNodeBroker
type CdServerOption ¶
type CdServerOption func(*CdServer)
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
func CdServerNodeOption ¶
func CdServerNodeOption(options ...CdNodeOption) CdServerOption
func CdServerS3Option ¶
func CdServerS3Option(s3AK, s3SK, s3Endpoint, s3Bucket, s3Region, s3getToolUrl string) CdServerOption
type CdService ¶
type DefaultCdService ¶ added in v1.1.0
type DefaultCdService struct {
// contains filtered or unexported fields
}
func (*DefaultCdService) GetCdScript ¶ added in v1.1.0
func (t *DefaultCdService) GetCdScript() *CdScript
func (*DefaultCdService) GetName ¶ added in v1.1.0
func (t *DefaultCdService) GetName() string
func (*DefaultCdService) GetParams ¶ added in v1.1.0
func (t *DefaultCdService) GetParams() map[string]string
func (*DefaultCdService) IncDeployCounter ¶ added in v1.1.0
func (t *DefaultCdService) IncDeployCounter() uint32
func (*DefaultCdService) UpdatePkgUrl ¶ added in v1.1.0
func (t *DefaultCdService) UpdatePkgUrl(pkgUrl string)
implements
type DeployResult ¶
Click to show internal directories.
Click to hide internal directories.