Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CachedFile ¶ added in v0.5.0
type CachedFile struct {
FileID string
}
CachedFile defines file cached in the file store
func (*CachedFile) String ¶ added in v0.8.3
func (f *CachedFile) String() string
type Cmd ¶
type Cmd struct {
Args []string
Env []string
Files []CmdFile
CPULimit time.Duration
ClockLimit time.Duration
MemoryLimit Size
StackLimit Size
OutputLimit Size
ProcLimit uint64
OpenFileLimit uint64
CPURateLimit uint64
CPUSetLimit string
CopyIn map[string]CmdFile
Symlinks map[string]string
CopyOut []CmdCopyOutFile
CopyOutCached []CmdCopyOutFile
CopyOutMax uint64
CopyOutDir string
TTY bool
DataSegmentLimit bool
AddressSpaceLimit bool
}
Cmd defines command and limits to start a program using in envexec
type CmdCopyOutFile ¶ added in v1.2.1
type CmdCopyOutFile = envexec.CmdCopyOutFile
type CmdFile ¶
type CmdFile interface {
// EnvFile prepares file for envexec file
EnvFile(fs filestore.FileStore) (envexec.File, error)
// Stringer to print debug information
fmt.Stringer
}
CmdFile defines file used in the cmd
type Collector ¶ added in v1.3.1
type Collector struct {
Name string // pseudo name generated into copyOut
Max envexec.Size // max size to be collected
Pipe bool
}
Collector defines on the output (stdout / stderr) to be collected over pipe
type Config ¶ added in v0.8.1
type Config struct {
FileStore filestore.FileStore
EnvironmentPool EnvironmentPool
Parallelism int
WorkDir string
TimeLimitTickInterval time.Duration
ExtraMemoryLimit envexec.Size
OutputLimit envexec.Size
CopyOutLimit envexec.Size
OpenFileLimit uint64
ExecObserver func(Response)
}
Config defines worker configuration
type EnvironmentPool ¶ added in v1.1.0
type EnvironmentPool interface {
Get() (envexec.Environment, error)
Put(envexec.Environment)
Destroy()
}
EnvironmentPool defines pools for environment to be used to execute commands
type LocalFile ¶ added in v0.5.0
type LocalFile struct {
Src string
}
LocalFile defines file stores on the local file system
type MemoryFile ¶ added in v0.5.0
type MemoryFile struct {
Content []byte
}
MemoryFile defines file stores in the memory
func (*MemoryFile) String ¶ added in v0.8.3
func (f *MemoryFile) String() string
type Result ¶
type Result struct {
Status envexec.Status
ExitStatus int
Error string
Time time.Duration
RunTime time.Duration
Memory Size
ProcPeak uint64
Files map[string]*os.File
FileIDs map[string]string
FileError []FileError
}
Result defines single command response
Click to show internal directories.
Click to hide internal directories.