Documentation
¶
Index ¶
- type ConfigInterface
- type Factory
- type Job
- func (j *Job) AddJobAsNeed(job *Job) *Job
- func (j *Job) AddName(name string) *Job
- func (j *Job) AddNeedByStage(job *Job, stage stages.Stage) *Job
- func (j *Job) AddSeveralNeeds(needs *Needs) *Job
- func (j *Job) DynamicMerge(jobs *Jobs) (*Job, error)
- func (j *Job) EvaluateName(jobs *Jobs) (*Job, error)
- func (j *Job) GetName() string
- func (j *Job) RemoveNeed(need *Need) bool
- func (j *Job) Render() error
- func (j *Job) RenderNeeds() (*Job, error)
- func (j *Job) UniqueName() error
- type Jobs
- func (j *Jobs) AddJob(job *Job) *Jobs
- func (j *Jobs) DynamicMerge() (*Jobs, error)
- func (j *Jobs) EvaluateNames() (*Jobs, error)
- func (j *Jobs) FindJobsByPipelineId(pipelineId string) (*Jobs, error)
- func (j *Jobs) GetJobs() []*Job
- func (j *Jobs) OverwriteTags(tags []string)
- func (j *Jobs) SanityCheck() error
- func (j *Jobs) SetJobsAsNeed(jobs *Jobs) *Jobs
- type Need
- type Needs
- func (n *Needs) AddNeed(need *Need) *Needs
- func (n *Needs) GetNeed(job *Job) *Need
- func (n *Needs) GetNeeds() []*Need
- func (n *Needs) HasJob(job *Job) bool
- func (n *Needs) HasNeed(need *Need) bool
- func (n *Needs) NeedsYaml() *job.NeedsYaml
- func (n *Needs) RemoveJob(job *Job) bool
- func (n *Needs) RemoveNeed(need *Need) bool
- func (n *Needs) ReplaceJob(old *Job, new *Need) *Needs
- type PipelineBuilderInterface
- type PipelineBuilderWrapper
- type PipelineConfig
- type PipelineConfigInterface
- type PipelineConfigTypeMap
- type PipelineType
- type PipelineTypeConfig
- type PipelineTypeConfigInterface
- type PipelineTypes
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConfigInterface ¶
type ConfigInterface interface {
Validate() error
}
type Factory ¶
type Factory interface { GetGitlabClient() *gitlab.Client GetVersionController() *version.Controller }
type Job ¶
type Job struct { Names []string CiJob *job.CiJob Needs Needs CiJobYaml *job.CiJobYaml PipelineId string ExternalTags []string // contains filtered or unexported fields }
func (*Job) AddJobAsNeed ¶
func (*Job) AddSeveralNeeds ¶
func (*Job) RemoveNeed ¶
func (*Job) RenderNeeds ¶
func (*Job) UniqueName ¶
type Jobs ¶
type Jobs []*Job
func GetPipelineJobs ¶
func GetPipelineJobs(factory Factory, config PipelineConfigInterface, pipelineType PipelineType, pipelineId string) (*Jobs, error)
func LoadJobsFromPipelineConfig ¶
func LoadJobsFromPipelineConfig(factory Factory, pipelineConfig *PipelineConfig, configTypes *PipelineTypes) (*Jobs, error)
func (*Jobs) DynamicMerge ¶
func (*Jobs) EvaluateNames ¶
func (*Jobs) FindJobsByPipelineId ¶
func (*Jobs) OverwriteTags ¶
func (*Jobs) SanityCheck ¶
func (*Jobs) SetJobsAsNeed ¶
type Need ¶
func (*Need) NotOptional ¶
type PipelineBuilderInterface ¶
type PipelineBuilderInterface interface {
Build(pipelineTypeConfig PipelineTypeConfig) (*Jobs, error)
}
type PipelineBuilderWrapper ¶
type PipelineBuilderWrapper struct { Builder PipelineBuilderInterface PipelineTypeConfig PipelineTypeConfig }
func (*PipelineBuilderWrapper) Build ¶
func (p *PipelineBuilderWrapper) Build() (*Jobs, error)
type PipelineConfig ¶
type PipelineConfig struct { Noop bool `yaml:"noop,omitempty"` Versioning bool `yaml:"versioning,omitempty"` Tags []string `yaml:"tags"` DependencyProxy string `yaml:"dependencyProxy"` Pipelines []PipelineTypeConfig `yaml:"pipelines"` PrivateTokenName string `yaml:"privateTokenName"` }
func (*PipelineConfig) Decode ¶
func (p *PipelineConfig) Decode(factory Factory, configTypes PipelineConfigTypeMap) (*Jobs, error)
type PipelineConfigInterface ¶
type PipelineConfigInterface interface { New() PipelineConfigInterface ConfigInterface Build(factory Factory, pipelineType PipelineType, Id string) (*Jobs, error) Rules() *job.Rules }
type PipelineConfigTypeMap ¶
type PipelineConfigTypeMap map[PipelineType]PipelineConfigInterface
type PipelineType ¶
type PipelineType string
func (PipelineType) String ¶
func (p PipelineType) String() string
type PipelineTypeConfig ¶
type PipelineTypeConfig struct { Type PipelineType `yaml:"type"` Config interface{} `yaml:"config"` PipelineId string `yaml:"id"` Needs []string `yaml:"needs"` Tags []string `yaml:"tags"` }
func (*PipelineTypeConfig) Decode ¶
func (p *PipelineTypeConfig) Decode(factory Factory, configTypes PipelineConfigTypeMap) (*Jobs, error)
func (*PipelineTypeConfig) GetType ¶
func (p *PipelineTypeConfig) GetType() PipelineType
type PipelineTypeConfigInterface ¶
type PipelineTypeConfigInterface interface { Decode(configTypes *PipelineConfigTypeMap) error GetType() PipelineType }
type PipelineTypes ¶
type PipelineTypes struct {
// contains filtered or unexported fields
}
func NewPipelineTypes ¶
func NewPipelineTypes() *PipelineTypes
func (*PipelineTypes) Add ¶
func (p *PipelineTypes) Add(pipelineType PipelineType, config PipelineConfigInterface) *PipelineTypes
func (*PipelineTypes) GetTypesMap ¶
func (p *PipelineTypes) GetTypesMap() PipelineConfigTypeMap
func (*PipelineTypes) Remove ¶
func (p *PipelineTypes) Remove(pipelineType PipelineType) *PipelineTypes
Click to show internal directories.
Click to hide internal directories.