Documentation ¶
Index ¶
- Constants
- Variables
- func FormatLogPath(id string, config map[string]string)
- type CreateOpts
- type DeleteOpts
- type ExecOpts
- type KillOpts
- type Runsc
- func (r *Runsc) Create(context context.Context, id, bundle string, opts *CreateOpts) error
- func (r *Runsc) Delete(context context.Context, id string, opts *DeleteOpts) error
- func (r *Runsc) Events(context context.Context, id string, interval time.Duration) (chan *runc.Event, error)
- func (r *Runsc) Exec(context context.Context, id string, spec specs.Process, opts *ExecOpts) error
- func (r *Runsc) Kill(context context.Context, id string, sig int, opts *KillOpts) error
- func (r *Runsc) List(context context.Context) ([]*runc.Container, error)
- func (r *Runsc) Ps(context context.Context, id string) ([]int, error)
- func (r *Runsc) Run(context context.Context, id, bundle string, opts *CreateOpts) (int, error)
- func (r *Runsc) Start(context context.Context, id string, cio runc.IO) error
- func (r *Runsc) State(context context.Context, id string) (*runc.Container, error)
- func (r *Runsc) Stats(context context.Context, id string) (*runc.Stats, error)
- func (r *Runsc) Top(context context.Context, id string) (*runc.TopResults, error)
- func (r *Runsc) Wait(context context.Context, id string) (int, error)
Constants ¶
View Source
const DefaultCommand = "runsc"
DefaultCommand is the default command for Runsc
Variables ¶
View Source
var Monitor runc.ProcessMonitor = runc.Monitor
Functions ¶
func FormatLogPath ¶
FormatLogPath parses runsc config, and fill in %ID% in the log path.
Types ¶
type CreateOpts ¶
type DeleteOpts ¶
type DeleteOpts struct {
Force bool
}
type Runsc ¶
type Runsc struct { Command string PdeathSignal syscall.Signal Setpgid bool Root string Log string LogFormat runc.Format Config map[string]string }
Runsc is the client to the runsc cli
func (*Runsc) Create ¶
Create creates a new container and returns its pid if it was created successfully
func (*Runsc) Events ¶
func (r *Runsc) Events(context context.Context, id string, interval time.Duration) (chan *runc.Event, error)
Events returns an event stream from runsc for a container with stats and OOM notifications
func (*Runsc) Exec ¶
Exec executres and additional process inside the container based on a full OCI Process specification
func (*Runsc) Run ¶
Run runs the create, start, delete lifecycle of the container and returns its exit status after it has exited
Click to show internal directories.
Click to hide internal directories.