runtime: Fix virtiofs fd leak

The kata runtime invokes removeStaleVirtiofsShareMounts after
a container is stopped to clean up the stale virtiofs file caches.

Fixes: #6455
Signed-off-by: Feng Wang <fwang@confluent.io>
This commit is contained in:
Feng Wang
2023-04-26 15:38:08 -07:00
parent 509bc8b6c8
commit 205909fbed
12 changed files with 521 additions and 311 deletions

View File

@@ -141,6 +141,11 @@ func (n *mockAgent) waitProcess(ctx context.Context, c *Container, processID str
return 0, nil
}
// removeStaleVirtiofsShareMounts is the Noop agent removeStaleVirtiofsShareMounts implementation. It does nothing.
func (n *mockAgent) removeStaleVirtiofsShareMounts(ctx context.Context) error {
return nil
}
// winsizeProcess is the Noop agent process tty resizer. It does nothing.
func (n *mockAgent) winsizeProcess(ctx context.Context, c *Container, processID string, height, width uint32) error {
return nil