pipelines

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 21, 2026 License: Apache-2.0 Imports: 9 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package pipelines provides services for triggering CI/CD pipelines across different git providers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MultiProviderPipelineService

type MultiProviderPipelineService struct {
	// contains filtered or unexported fields
}

MultiProviderPipelineService dynamically dispatches pipeline operations to the correct provider based on git server settings.

func NewMultiProviderPipelineService

func NewMultiProviderPipelineService() *MultiProviderPipelineService

NewMultiProviderPipelineService creates a service with all available provider implementations.

func (*MultiProviderPipelineService) GetCache added in v0.3.0

GetCache returns the pipeline cache instance for cache management.

func (*MultiProviderPipelineService) ListPipelines added in v0.3.0

ListPipelines dispatches the pipeline listing request to the appropriate provider with caching.

func (*MultiProviderPipelineService) TriggerPipeline

func (m *MultiProviderPipelineService) TriggerPipeline(
	ctx context.Context,
	project string,
	ref string,
	variables []models.PipelineVariable,
	settings krci.GitServerSettings,
) (*models.PipelineResponse, error)

TriggerPipeline dispatches the pipeline trigger request to the appropriate provider based on the git provider specified in settings.

type PipelineProvider

type PipelineProvider interface {
	TriggerPipeline(
		ctx context.Context,
		project string,
		ref string,
		variables []models.PipelineVariable,
		settings krci.GitServerSettings,
	) (*models.PipelineResponse, error)

	ListPipelines(
		ctx context.Context,
		project string,
		settings krci.GitServerSettings,
		opts models.PipelineListOptions,
	) (*models.PipelinesResponse, error)
}

PipelineProvider defines the interface for CI/CD pipeline operations. This interface must be implemented by all git providers (GitLab, GitHub, Bitbucket).

type PipelinesService

type PipelinesService struct {
	// contains filtered or unexported fields
}

PipelinesService handles pipeline operations by coordinating between git server settings and provider-specific implementations.

func NewPipelinesService

func NewPipelinesService(
	pipelinesProvider *MultiProviderPipelineService,
	gitServerService *krci.GitServerService,
) *PipelinesService

NewPipelinesService creates a new PipelinesService.

func (*PipelinesService) GetProvider added in v0.3.0

GetProvider returns the underlying multi-provider service for direct access to its cache.

func (*PipelinesService) ListPipelines added in v0.3.0

func (s *PipelinesService) ListPipelines(
	ctx context.Context,
	gitServerName string,
	project string,
	opts models.PipelineListOptions,
) (*models.PipelinesResponse, error)

ListPipelines lists CI/CD pipelines for the specified git server and project. It fetches git server settings from Kubernetes and delegates to the appropriate provider.

func (*PipelinesService) TriggerPipeline

func (s *PipelinesService) TriggerPipeline(
	ctx context.Context,
	gitServerName string,
	project string,
	ref string,
	variables []models.PipelineVariable,
) (*models.PipelineResponse, error)

TriggerPipeline triggers a CI/CD pipeline for the specified git server, project, and ref. It fetches git server settings from Kubernetes and delegates to the appropriate provider.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL