repo

package
v0.0.0-...-642d354 Latest Latest
Warning

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

Go to latest
Published: May 15, 2021 License: AGPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BuildService

type BuildService struct {
	Datastore datastore.Datastore
	LXDSrv    lxd.Service
}

BuildService implements a build service

func NewBuildService

func NewBuildService(ds datastore.Datastore, lx lxd.Service) *BuildService

NewBuildService creates a new build service

func (*BuildService) Build

func (bld *BuildService) Build(repoID string) (string, error)

Build starts a build with lxd

func (*BuildService) BuildDelete

func (bld *BuildService) BuildDelete(id string) error

BuildDelete deletes a build with its logs and snap

func (*BuildService) BuildGet

func (bld *BuildService) BuildGet(id string) (domain.Build, error)

BuildGet returns a build with its logs

func (*BuildService) List

func (bld *BuildService) List() ([]domain.Build, error)

List returns a list of the builds that have been requested

func (*BuildService) RepoCreate

func (bld *BuildService) RepoCreate(repo, branch, keyID string) (string, error)

RepoCreate creates a new repo

func (*BuildService) RepoDelete

func (bld *BuildService) RepoDelete(id string, deleteBuilds bool) error

RepoDelete removes a repo and optionally removes its builds

func (*BuildService) RepoList

func (bld *BuildService) RepoList(watch bool) ([]domain.Repo, error)

RepoList returns a list of repos

type BuildSrv

type BuildSrv interface {
	Build(repoID string) (string, error)
	List() ([]domain.Build, error)
	BuildGet(id string) (domain.Build, error)
	BuildDelete(id string) error

	RepoCreate(repo, branch, keyID string) (string, error)
	RepoList(watch bool) ([]domain.Repo, error)
	RepoDelete(id string, deleteBuilds bool) error
}

BuildSrv interface for building images

Jump to

Keyboard shortcuts

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