kata 2.0: delete use_vsock option and proxy abstraction

With kata containers moving to 2.0, (hybrid-)vsock will be the only
way to directly communicate between host and agent.
And kata-proxy as additional component to handle the multiplexing on
serial port is also no longer needed.
Cleaning up related unit tests, and also add another mock socket type
`MockHybridVSock` to deal with ttrpc-based hybrid-vsock mock server.

Fixes: #389

Signed-off-by: Penny Zheng penny.zheng@arm.com
This commit is contained in:
Penny Zheng
2020-07-13 02:21:10 +00:00
parent c052e46c66
commit 1099a28830
68 changed files with 427 additions and 2374 deletions

View File

@@ -235,12 +235,12 @@ func BuildSocketPath(elements ...string) (string, error) {
}
// SupportsVsocks returns true if vsocks are supported, otherwise false
func SupportsVsocks() bool {
func SupportsVsocks() (bool, error) {
if _, err := os.Stat(VHostVSockDevicePath); err != nil {
return false
return false, fmt.Errorf("host system doesn't support vsock: %v", err)
}
return true
return true, nil
}
// SupportsIfb returns true if ifb are supported, otherwise false