Documentation
¶
Index ¶
- Variables
- func CheckContainerMounts(workspace, state string, writable bool) error
- func Configure(cmd *exec.Cmd)
- func OwnContainer(owner containerapi.Owner) (func() error, error)
- func ReadCompletion(path, token string) error
- func RunContainerWorkload(ctx context.Context, path, token string, argv []string) (int, error)
- func Supervise(cmd *exec.Cmd) (func(), error)
- func SuperviseWithCleanup(cmd *exec.Cmd, cleanupArgs []string) (func(), error)
- func SuperviseWithOptions(cmd *exec.Cmd, options SupervisionOptions) (func(), error)
- type Completion
- type SupervisionOptions
Constants ¶
This section is empty.
Variables ¶
var ErrCleanup = errors.New("execution cleanup could not be confirmed")
ErrCleanup means execution cleanup was not confirmed. It must remain visible even when a cancellation also occurred; callers must suspend further turns.
Functions ¶
func CheckContainerMounts ¶
func OwnContainer ¶
func OwnContainer(owner containerapi.Owner) (func() error, error)
OwnContainer starts an independent host guardian before the create request. Closing its private pipe (also on controller death) triggers verified cleanup. The workload guardian additionally prevents a delayed start after owner loss.
func ReadCompletion ¶
func RunContainerWorkload ¶
RunContainerWorkload requires a changing controller lifetime record before effects. A frozen record cannot start work after VM/runtime recovery. While running, the monotonic local deadline avoids host/VM wall-clock assumptions.
func Supervise ¶
Supervise wraps a not-yet-started command. Call cleanup after Wait/Run, even when Start fails. The original command's streams, directory and environment are preserved; no shell interprets its arguments.
func SuperviseWithCleanup ¶
func SuperviseWithOptions ¶
func SuperviseWithOptions(cmd *exec.Cmd, options SupervisionOptions) (func(), error)