tart

package
v0.74.1 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2022 License: MPL-2.0 Imports: 14 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

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrTartNotFound = errors.New("tart command not found")
	ErrTartFailed   = errors.New("tart command returned non-zero exit code")
)
View Source
var (
	ErrFailed = errors.New("tart isolation failed")
)

Functions

func Cmd

func Cmd(ctx context.Context, args ...string) (string, string, error)

Types

type Option

type Option func(*Tart)

func WithLogger

func WithLogger(logger logger.Lightweight) Option

type Tart

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

func New

func New(vmName string, sshUser string, sshPassword string, cpu uint32, memory uint32, opts ...Option) (*Tart, error)

func (*Tart) Close

func (tart *Tart) Close() error

func (*Tart) Run

func (tart *Tart) Run(ctx context.Context, config *runconfig.RunConfig) (err error)

func (*Tart) WorkingDirectory

func (tart *Tart) WorkingDirectory(projectDir string, dirtyMode bool) string

type VM

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

func NewVMClonedFrom

func NewVMClonedFrom(ctx context.Context, from string, cpu uint32, memory uint32) (*VM, error)

func (*VM) Close

func (vm *VM) Close() error

func (*VM) ErrChan

func (vm *VM) ErrChan() chan error

func (*VM) Ident

func (vm *VM) Ident() string

func (*VM) RetrieveIP

func (vm *VM) RetrieveIP(ctx context.Context) (string, error)

func (*VM) Start

func (vm *VM) Start()

Jump to

Keyboard shortcuts

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