mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-06-29 16:57:18 +00:00
cache: Call vm.Disconnect() when close vm
After previous commit, found that kata-proxy is not quit when vmcache server is stopped by ctrl-c. The cause is current kata-proxy is setsid when it exec. It will not get the signal ctrl-c. Call vm.Disconnect() when close vm in cache factory to handle this issue. Fixes: #1726 Signed-off-by: Hui Zhu <teawater@hyper.sh>
This commit is contained in:
parent
19115ef5f1
commit
7bf6c6754d
1
virtcontainers/factory/cache/cache.go
vendored
1
virtcontainers/factory/cache/cache.go
vendored
@ -63,6 +63,7 @@ func New(ctx context.Context, count uint, b base.FactoryBase) base.FactoryBase {
|
||||
case <-closed:
|
||||
c.removeFromVmm(vm)
|
||||
vm.Stop()
|
||||
vm.Disconnect()
|
||||
c.wg.Done()
|
||||
return
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user