runners

package
v0.53.0 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2025 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRunnerService

func NewRunnerService(config RunnerServiceConfig) services.IRunnerService

Types

type RunnerService

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

func (*RunnerService) Create

func (*RunnerService) Delete

func (s *RunnerService) Delete(ctx context.Context, runnerId string) error

func (*RunnerService) Find

func (s *RunnerService) Find(ctx context.Context, runnerId string) (*services.RunnerDTO, error)

func (*RunnerService) GetRunnerLogReader

func (s *RunnerService) GetRunnerLogReader(ctx context.Context, runnerId string) (io.Reader, error)

func (*RunnerService) GetRunnerLogWriter

func (s *RunnerService) GetRunnerLogWriter(ctx context.Context, runnerId string) (io.WriteCloser, error)

func (*RunnerService) InstallProvider

func (s *RunnerService) InstallProvider(ctx context.Context, runnerId, name, version, registryUrl string) error

func (*RunnerService) List

func (s *RunnerService) List(ctx context.Context) ([]*services.RunnerDTO, error)

func (*RunnerService) ListProviders

func (s *RunnerService) ListProviders(ctx context.Context, runnerId *string) ([]models.ProviderInfo, error)

func (*RunnerService) ListProvidersForInstall

func (s *RunnerService) ListProvidersForInstall(ctx context.Context, registryUrl string) ([]services.ProviderDTO, error)

func (*RunnerService) ListRunnerJobs

func (s *RunnerService) ListRunnerJobs(ctx context.Context, runnerId string) ([]*models.Job, error)

func (*RunnerService) UninstallProvider

func (s *RunnerService) UninstallProvider(ctx context.Context, runnerId string, providerName string) error

func (*RunnerService) UpdateJobState

func (s *RunnerService) UpdateJobState(ctx context.Context, jobId string, req services.UpdateJobStateDTO) error

func (*RunnerService) UpdateMetadata

func (s *RunnerService) UpdateMetadata(ctx context.Context, runnerId string, metadata *models.RunnerMetadata) error

func (*RunnerService) UpdateProvider

func (s *RunnerService) UpdateProvider(ctx context.Context, runnerId, name, version, registryUrl string) error

type RunnerServiceConfig

type RunnerServiceConfig struct {
	RunnerStore         stores.RunnerStore
	RunnerMetadataStore stores.RunnerMetadataStore
	LoggerFactory       logs.ILoggerFactory

	CreateJob          func(ctx context.Context, runnerId string, action models.JobAction, metadata string) error
	ListJobsForRunner  func(ctx context.Context, runnerId string) ([]*models.Job, error)
	UpdateJobState     func(ctx context.Context, jobId string, updateJobStateDto services.UpdateJobStateDTO) error
	CreateApiKey       func(ctx context.Context, name string) (string, error)
	DeleteApiKey       func(ctx context.Context, name string) error
	UnsetDefaultTarget func(ctx context.Context, runnerId string) error

	TrackTelemetryEvent func(event telemetry.Event, clientId string) error
}

Jump to

Keyboard shortcuts

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