Help us shape the future of Go! Take the 2026 Go Developer Survey

exec

package
v0.44.0 Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2026 License: MIT Imports: 6 Imported by: 28

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ProcessOption

type ProcessOption interface {
	Apply(opts *ProcessOptions)
}

ProcessOption defines a common interface to modify the reader processor These options can be passed to the Exec function in a variadic way to customize the returned Reader instance

func Multiplexed

func Multiplexed() ProcessOption

Multiplexed returns a ProcessOption that configures the command execution to combine stdout and stderr into a single stream without Docker's multiplexing headers.

func WithEnv added in v0.27.0

func WithEnv(env []string) ProcessOption

func WithUser added in v0.27.0

func WithUser(user string) ProcessOption

func WithWorkingDir added in v0.27.0

func WithWorkingDir(workingDir string) ProcessOption

type ProcessOptionFunc

type ProcessOptionFunc func(opts *ProcessOptions)

func (ProcessOptionFunc) Apply

func (fn ProcessOptionFunc) Apply(opts *ProcessOptions)

type ProcessOptions

type ProcessOptions struct {
	ExecConfig client.ExecCreateOptions
	Reader     io.Reader
}

ProcessOptions defines options applicable to the reader processor

func NewProcessOptions added in v0.27.0

func NewProcessOptions(cmd []string) *ProcessOptions

NewProcessOptions returns a new ProcessOptions instance with the given command and default options: - detach: false - attach stdout: true - attach stderr: true

Jump to

Keyboard shortcuts

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