containerd/execution/executor.go
Kenfe-Mickael Laventure c857213b4c move work on execution service
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2016-12-05 14:15:03 -08:00

36 lines
712 B
Go

package execution
import (
"io"
"os"
"github.com/opencontainers/runtime-spec/specs-go"
)
type CreateOpts struct {
Bundle string
Stdin io.Reader
Stdout io.Writer
Stderr io.Writer
}
type CreateProcessOpts struct {
Spec specs.Process
Stdin io.Reader
Stdout io.Writer
Stderr io.Writer
}
type Executor interface {
Create(id string, o CreateOpts) (*Container, error)
Pause(*Container) error
Resume(*Container) error
Status(*Container) (Status, error)
List() ([]*Container, error)
Load(id string) (*Container, error)
Delete(*Container) error
StartProcess(*Container, CreateProcessOpts) (Process, error)
SignalProcess(*Container, os.Signal) error
DeleteProcess(*Container, string) error
}