Add Kill API for shim service
Signed-off-by: Qiang Huang <h.huangqiang@huawei.com>
This commit is contained in:
parent
2048f891d2
commit
6132bec05a
13 changed files with 284 additions and 59 deletions
|
@ -158,6 +158,12 @@ func (p *initProcess) Resume(context context.Context) error {
|
|||
return p.runc.Resume(context, p.id)
|
||||
}
|
||||
|
||||
func (p *initProcess) Kill(context context.Context, signal uint32, all bool) error {
|
||||
return p.runc.Kill(context, p.id, int(signal), &runc.KillOpts{
|
||||
All: all,
|
||||
})
|
||||
}
|
||||
|
||||
func (p *initProcess) killAll(context context.Context) error {
|
||||
return p.runc.Kill(context, p.id, int(syscall.SIGKILL), &runc.KillOpts{
|
||||
All: true,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue