runner

package
v0.0.0-...-d70162c Latest Latest
Warning

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

Go to latest
Published: Jun 4, 2021 License: AGPL-3.0 Imports: 17 Imported by: 0

Documentation

Overview

Package runner is a main business layer of service.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Executor

type Executor interface {
	Execute(ctx context.Context, command string) (string, error)
	HomeDirectory(dir string)
}

Executor implementation of workers to perform jobs.

type GitlabAPI

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

GitlabAPI represent API for interacting with Gitlab.

func NewGitlabAPI

func NewGitlabAPI(client *http.Client, base string) *GitlabAPI

NewGitlabAPI create new Gitlab API instance.

type Service

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

Service represent main service struct.

func NewService

func NewService(logger *logrus.Entry, config *config.Config, gitlab gitlabAPI, executor Executor) *Service

NewService create new Service instance.

func (*Service) Process

func (s *Service) Process(ctx context.Context) error

Process run main Gitlab-gitlab-runner process.

func (*Service) Registration

func (s *Service) Registration(ctx context.Context, token string) (string, error)

Registration register new gitlab-runner in Gitlab.

Jump to

Keyboard shortcuts

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