client

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2018 License: Apache-2.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 MakisuClient

type MakisuClient struct {
	LocalSharedPath  string
	WorkerSharedPath string

	WorkerLog func(line string)
	HTTPDo    func(req *http.Request) (*http.Response, error)
}

MakisuClient is the struct that allows communication with a makisu worker.

func New

func New(socket, localPath, workerPath string) *MakisuClient

New creates a new Makisu client that will talk to the worker available on the socket passed in.

func (*MakisuClient) Build

func (cli *MakisuClient) Build(flags []string, context string) error

Build kicks off a build on the makisu worker at the context with the flags passed in.

func (*MakisuClient) Exit

func (cli *MakisuClient) Exit() error

Exit tells the makisu worker to exit cleanly.

func (*MakisuClient) Ready

func (cli *MakisuClient) Ready() (bool, error)

Ready returns true if the worker is ready for work, and false if it is already performing a build.

func (*MakisuClient) SetWorkerLog

func (cli *MakisuClient) SetWorkerLog(fn func(line string))

SetWorkerLog sets the function called on every worker log line.

Jump to

Keyboard shortcuts

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