libacherus

package
v0.0.0-...-a2c81f9 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2024 License: GPL-3.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AskForConfirmation

func AskForConfirmation(globalOptions *AcherusGlobalOptions, s string) bool

func AttachContainer

func AttachContainer(globalOptions *AcherusGlobalOptions, respID string) (types.HijackedResponse, error)

func BindDisplay

func BindDisplay(globalOptions *AcherusGlobalOptions, respID string) error

func BuildImage

func BuildImage(globalOptions *AcherusGlobalOptions, commandOptions *AcherusInitOptions) (err error)

func CheckDockerDeamon

func CheckDockerDeamon() error

func ContainerExec

func ContainerExec(globalOptions *AcherusGlobalOptions, originalRespId string, commandOptions *AcherusGoOptions) error

func CreateContainer

func CreateContainer(globalOptions *AcherusGlobalOptions, commandOptions *AcherusGoOptions) (string, error)

func CreateDir

func CreateDir(dir string) error

func DeleteContainer

func DeleteContainer(globalOptions *AcherusGlobalOptions, commandOptions *AcherusDestroyOptions) (err error)

func DeleteDir

func DeleteDir(dir string) error

func FindContainerByName

func FindContainerByName(globalOptions *AcherusGlobalOptions, containerTag string) (exists bool, container types.Container, err error)

func InitContainerDir

func InitContainerDir(globalOptions *AcherusGlobalOptions, commandOptions *AcherusGoOptions) error

func IsDirCreated

func IsDirCreated(dir string) bool

func ListContainer

func ListContainer(globalOptions *AcherusGlobalOptions)

func ListImage

func ListImage(globalOptions *AcherusGlobalOptions)

func PullImage

func PullImage(globalOptions *AcherusGlobalOptions) (err error)

func ResetImage

func ResetImage(globalOptions *AcherusGlobalOptions, commandOptions *AcherusResetOptions) (err error)

func SetupTty

func SetupTty(globalOptions *AcherusGlobalOptions, respID string, waiter types.HijackedResponse, exec bool) (*terminal.State, int, error)

func StartContainerAndAttach

func StartContainerAndAttach(respID string, globalOptions *AcherusGlobalOptions, commandOptions *AcherusGoOptions) error

func StopContainer

func StopContainer(globalOptions *AcherusGlobalOptions, commandOptions *AcherusSuspendOptions) (err error)

func WaitExecContainer

func WaitExecContainer(globalOptions *AcherusGlobalOptions, execID string, commandOptions *AcherusGoOptions) error

Types

type AcherusDestroyOptions

type AcherusDestroyOptions struct {
	ContainerTag string
	Force        bool
	Purge        bool
}

func NewDestroyOptions

func NewDestroyOptions() *AcherusDestroyOptions

type AcherusGlobalOptions

type AcherusGlobalOptions struct {
	Context      context.Context
	DockerClient *client.Client
	Logger       *AcherusOutput
	AcherusDir   string
	ContainerTag string
}

func NewGlobalOptions

func NewGlobalOptions() (*AcherusGlobalOptions, error)

type AcherusGoOptions

type AcherusGoOptions struct {
	Detach                   bool
	Nat                      bool
	Mount                    string
	ContainerTag             string
	Command                  []string
	Privileged               bool
	Local                    bool
	Recreate                 bool
	Clear                    bool
	ClearWithoutConfirmation bool
	NetworkAdmin             bool
}

func NewGoOptions

func NewGoOptions() *AcherusGoOptions

type AcherusInitOptions

type AcherusInitOptions struct {
	Local          bool
	DockerfilePath string
}

func NewInitOptions

func NewInitOptions() *AcherusInitOptions

type AcherusListOptions

type AcherusListOptions struct {
}

func NewListOptions

func NewListOptions() *AcherusListOptions

type AcherusOutput

type AcherusOutput struct {
	Verbose bool
}

func NewAcherusOutput

func NewAcherusOutput() *AcherusOutput

func (AcherusOutput) ClassicOutput

func (out AcherusOutput) ClassicOutput(message string, level string)

func (AcherusOutput) LoadingBuildOutput

func (out AcherusOutput) LoadingBuildOutput(scanner *bufio.Scanner, message string) error

func (AcherusOutput) LoadingPullOutput

func (out AcherusOutput) LoadingPullOutput(scanner *bufio.Scanner, message string) error

func (AcherusOutput) Output

func (out AcherusOutput) Output(message string, level string, icon string, prefix string)

func (AcherusOutput) SimpleLoadingOutput

func (out AcherusOutput) SimpleLoadingOutput(scanner *bufio.Scanner, message string)

type AcherusResetOptions

type AcherusResetOptions struct {
}

func NewResetOptions

func NewResetOptions() *AcherusResetOptions

type AcherusSuspendOptions

type AcherusSuspendOptions struct {
	ContainerTag string
}

func NewSuspendOptions

func NewSuspendOptions() *AcherusSuspendOptions

type ImageBuildErrorDetail

type ImageBuildErrorDetail struct {
	Message string `json:"message"`
}

type ImageBuildErrorLine

type ImageBuildErrorLine struct {
	Error       string                `json:"error"`
	ErrorDetail ImageBuildErrorDetail `json:"errorDetail"`
}

type ImageBuildStream

type ImageBuildStream struct {
	Stream string `json:"stream"`
}

type ImagePullProgressDetail

type ImagePullProgressDetail struct {
	Current int64 `json:"current,omitempty"`
	Total   int64 `json:"total,omitempty"`
}

type ImagePullStream

type ImagePullStream struct {
	Status         string                  `json:"status"`
	Id             string                  `json:"id"`
	ProgressDetail ImagePullProgressDetail `json:"progressDetail,omitempty"`
	Progress       string                  `json:"progress,omitempty"`
}

type LoadingBarControlContent

type LoadingBarControlContent struct {
	CurrentValue, TotalValue int64
	Data                     map[string]*ImagePullProgressDetail
	Bar                      *pb.ProgressBar
	StatusMessage            string
	Finish                   bool
}

type OutputSegment

type OutputSegment struct {
	ImagePullStream                                *ImagePullStream
	Downloading, Downloaded, Extracting, Extracted bool
}

type OutputSegmentMap

type OutputSegmentMap map[string]*OutputSegment

Jump to

Keyboard shortcuts

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