API: remove ProcessListContainer/ListProcesses

This commit will remove ProcessListContainer API from VCSandbox
and ListProcesses from agent.proto.

Fixes: #1668

Signed-off-by: bin <bin@hyper.sh>
This commit is contained in:
bin
2021-04-09 16:03:29 +08:00
parent d75fe95685
commit 421439c633
17 changed files with 255 additions and 1012 deletions

View File

@@ -1273,19 +1273,6 @@ func (s *Sandbox) DeleteContainer(ctx context.Context, containerID string) (VCCo
return c, nil
}
// ProcessListContainer lists every process running inside a specific
// container in the sandbox.
func (s *Sandbox) ProcessListContainer(ctx context.Context, containerID string, options ProcessListOptions) (ProcessList, error) {
// Fetch the container.
c, err := s.findContainer(containerID)
if err != nil {
return nil, err
}
// Get the process list related to the container.
return c.processList(ctx, options)
}
// StatusContainer gets the status of a container
// TODO: update container status properly, see kata-containers/runtime#253
func (s *Sandbox) StatusContainer(containerID string) (ContainerStatus, error) {