Documentation ¶
Index ¶
- Constants
- Variables
- func ApproveActivity(provider model.PipelineProvider, activity *model.Activity) error
- func CleanAccounts(scmType string) ([]*model.GitAccount, error)
- func CleanPipeline(p *model.Pipeline)
- func CreateAccount(account *model.GitAccount) error
- func CreateActivity(activity *model.Activity) error
- func CreateCredential(cred *model.Credential) error
- func CreateOrUpdateCacheRepoList(accountId string, repos []*model.GitRepository) error
- func CreateOrUpdateEnvKey(clientId string, token string) error
- func CreateOrUpdatePipelineSetting(setting *model.PipelineSetting) error
- func CreateOrUpdateSCMSetting(setting *model.SCMSetting) error
- func CreatePipeline(pipeline *model.Pipeline) error
- func DeleteActivity(id string) error
- func DeletePipeline(id string) (*model.Pipeline, error)
- func DenyActivity(activity *model.Activity) error
- func FailStep(activity *model.Activity, stageOrdinal int, stepOrdinal int)
- func GetAccount(id string) (*model.GitAccount, error)
- func GetActivity(id string) (*model.Activity, error)
- func GetAllServices(activity *model.Activity) []*model.CIService
- func GetCacheRepoList(accountId string) ([]*model.GitRepository, error)
- func GetEnvKey(clientId string) (string, error)
- func GetNextRunTime(pipeline *model.Pipeline) int64
- func GetPipelineById(id string) (*model.Pipeline, error)
- func GetPipelineSetting() (*model.PipelineSetting, error)
- func GetSCMSetting(scmType string) (*model.SCMSetting, error)
- func GetSCManager(scmType string) (model.SCManager, error)
- func GetSCManagerFromSetting(s *model.SCMSetting) (model.SCManager, error)
- func GetSCManagerFromUserID(userId string) (model.SCManager, error)
- func GetServices(activity *model.Activity, stageOrdinal int, stepOrdinal int) []*model.CIService
- func GetUserToken(gitUser string) (string, error)
- func HasStageCondition(s *model.Stage) bool
- func HasStepCondition(s *model.Step) bool
- func IsComplete(activity *model.Activity) bool
- func IsStageSuccess(stage *model.ActivityStage) bool
- func IsValidName(name string) error
- func ListAccounts(uid string) ([]*model.GitAccount, error)
- func ListActivities() ([]*model.Activity, error)
- func ListPipelines() []*model.Pipeline
- func ListSCMSetting() []*model.SCMSetting
- func PaginateGenericObjects(kind string) ([]client.GenericObject, error)
- func RefreshRepos(accountId string) ([]*model.GitRepository, error)
- func RemoveAccount(id string) (*model.GitAccount, error)
- func RemoveSCMSetting(id string) (*model.SCMSetting, error)
- func RerunActivity(provider model.PipelineProvider, activity *model.Activity) error
- func Reset() error
- func ResetActivityStatus(activity *model.Activity)
- func RunPipeline(provider model.PipelineProvider, id string, triggerType string) (*model.Activity, error)
- func ShareAccount(id string) (*model.GitAccount, error)
- func StartStep(activity *model.Activity, stageOrdinal int, stepOrdinal int)
- func StopActivity(provider model.PipelineProvider, activity *model.Activity) error
- func SuccessStep(activity *model.Activity, stageOrdinal int, stepOrdinal int)
- func SyncActivity(provider model.PipelineProvider, activity *model.Activity) error
- func Triggernext(activity *model.Activity, stageOrdinal int, stepOrdinal int, ...)
- func UnshareAccount(id string) (*model.GitAccount, error)
- func UpdateAccount(account *model.GitAccount) error
- func UpdateActivity(activity *model.Activity) error
- func UpdateCredential(cred *model.Credential) error
- func UpdatePipeline(pipeline *model.Pipeline) error
- func UpdatePipelineEnvKey(p *model.Pipeline) error
- func ValidAccountAccess(req *http.Request, accountId string) bool
- func ValidAccountAccessById(uid string, accountId string) bool
- func Validate(p *model.Pipeline) error
Constants ¶
View Source
const GIT_ACCOUNT_TYPE = "gitaccount"
View Source
const REPO_CACHE_TYPE = "repocache"
Variables ¶
View Source
var ErrInvalidPipeline = errors.New("Invalid Pipeline definition")
Functions ¶
func ApproveActivity ¶
func ApproveActivity(provider model.PipelineProvider, activity *model.Activity) error
func CleanAccounts ¶
func CleanAccounts(scmType string) ([]*model.GitAccount, error)
func CleanPipeline ¶
func CreateAccount ¶
func CreateAccount(account *model.GitAccount) error
func CreateActivity ¶
func CreateCredential ¶
func CreateCredential(cred *model.Credential) error
func CreateOrUpdateCacheRepoList ¶
func CreateOrUpdateCacheRepoList(accountId string, repos []*model.GitRepository) error
func CreateOrUpdateEnvKey ¶
func CreateOrUpdatePipelineSetting ¶
func CreateOrUpdatePipelineSetting(setting *model.PipelineSetting) error
func CreateOrUpdateSCMSetting ¶
func CreateOrUpdateSCMSetting(setting *model.SCMSetting) error
func CreatePipeline ¶
func DeleteActivity ¶
func DenyActivity ¶
func GetAccount ¶
func GetAccount(id string) (*model.GitAccount, error)
func GetActivity ¶
Get Activity From GenericObjects By Id
func GetAllServices ¶
GetAllServices gets all run services of the activity
func GetCacheRepoList ¶
func GetCacheRepoList(accountId string) ([]*model.GitRepository, error)
func GetNextRunTime ¶
func GetPipelineSetting ¶
func GetPipelineSetting() (*model.PipelineSetting, error)
func GetSCMSetting ¶
func GetSCMSetting(scmType string) (*model.SCMSetting, error)
func GetSCManagerFromSetting ¶
func GetSCManagerFromSetting(s *model.SCMSetting) (model.SCManager, error)
func GetServices ¶
GetServices gets run services before the step
func GetUserToken ¶
func HasStageCondition ¶
func HasStepCondition ¶
func IsComplete ¶
func IsStageSuccess ¶
func IsStageSuccess(stage *model.ActivityStage) bool
func IsValidName ¶
IsValidName checks if name valid. limit to [a-zA-Z0-9-_]
func ListAccounts ¶
func ListAccounts(uid string) ([]*model.GitAccount, error)
listAccounts gets scm accounts accessible by the user
func ListActivities ¶
func ListSCMSetting ¶
func ListSCMSetting() []*model.SCMSetting
func PaginateGenericObjects ¶
func RefreshRepos ¶
func RefreshRepos(accountId string) ([]*model.GitRepository, error)
func RemoveAccount ¶
func RemoveAccount(id string) (*model.GitAccount, error)
func RemoveSCMSetting ¶
func RemoveSCMSetting(id string) (*model.SCMSetting, error)
func RerunActivity ¶
func RerunActivity(provider model.PipelineProvider, activity *model.Activity) error
func ResetActivityStatus ¶
resetActivityStatus reset status and timestamp
func RunPipeline ¶
func ShareAccount ¶
func ShareAccount(id string) (*model.GitAccount, error)
func StopActivity ¶
func StopActivity(provider model.PipelineProvider, activity *model.Activity) error
func SyncActivity ¶
func SyncActivity(provider model.PipelineProvider, activity *model.Activity) error
get updated activity from provider
func Triggernext ¶
func UnshareAccount ¶
func UnshareAccount(id string) (*model.GitAccount, error)
func UpdateAccount ¶
func UpdateAccount(account *model.GitAccount) error
func UpdateActivity ¶
func UpdateCredential ¶
func UpdateCredential(cred *model.Credential) error
func UpdatePipeline ¶
func UpdatePipelineEnvKey ¶
func ValidAccountAccessById ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.