协议
控制器
在 fuchsia.starnix.container/controller.fidl 中定义
GetJobHandle
返回容器的作业句柄。
请求
<空>
响应
| 名称 | 类型 | 
|---|---|
| payload | Controller_GetJobHandle_Result | 
GetVmoReferences
返回具有打开文件(由采用 koid 的 vmo 提供支持)的所有进程。
请求
| 名称 | 类型 | 
|---|---|
| payload | ControllerGetVmoReferencesRequest | 
响应
| 名称 | 类型 | 
|---|---|
| payload | Controller_GetVmoReferences_Result | 
SpawnConsole
生成一个用于在容器中调试的控制台。对于测试,最好启动 Linux 程序
作为组件与 starnix_container 运行程序一起运行。
在控制台退出时返回。
请求
| 名称 | 类型 | 
|---|---|
| payload | ControllerSpawnConsoleRequest | 
响应
| 名称 | 类型 | 
|---|---|
| payload | Controller_SpawnConsole_Result | 
VsockConnect
将 bridge_socket 连接到容器中 port 的 vsocket。
请求
| 名称 | 类型 | 
|---|---|
| payload | ControllerVsockConnectRequest | 
SocketTunnel
在 fuchsia.starnix.container/socket_tunnel.fidl 中定义
使用所提供的标签在远程端打开一个套接字, 并向本地客户端的套接字返回 zx::handle。
OpenSocket
请求
| 名称 | 类型 | 
|---|---|
| payload | SocketTunnelOpenSocketRequest | 
响应
| 名称 | 类型 | 
|---|---|
| payload | SocketTunnel_OpenSocket_Result | 
结构体
ConsoleWindowSize
在 fuchsia.starnix.container/controller.fidl 中定义
| 字段 | 类型 | 说明 | 默认 | 
|---|---|---|---|
| rows | uint16 | 无默认设置 | |
| cols | uint16 | 无默认设置 | |
| x_pixels | uint16 | 无默认设置 | |
| y_pixels | uint16 | 无默认设置 | 
Controller_SpawnConsole_Response
在 fuchsia.starnix.container/controller.fidl 中定义
| 字段 | 类型 | 说明 | 默认 | 
|---|---|---|---|
| exit_code | uint8 | 无默认设置 | 
精英
SpawnConsoleError 柔性
类型:uint32
在 fuchsia.starnix.container/controller.fidl 中定义
| 名称 | 值 | 说明 | 
|---|---|---|
| INVALID_ARGS | 1 | 某个必需的表格字段缺失或无效。 | 
| CANCELED | 2 | 控制台进程已退出,但没有正常的返回代码。 | 
表
ControllerGetVmoReferencesRequest
在 fuchsia.starnix.container/controller.fidl 中定义
| Ordinal | 字段 | 类型 | 说明 | 
|---|---|---|---|
| 1 | koid | uint64 | 
ControllerSpawnConsoleRequest 资源
在 fuchsia.starnix.container/controller.fidl 中定义
| Ordinal | 字段 | 类型 | 说明 | 
|---|---|---|---|
| 1 | console_in | handle<socket> | |
| 2 | console_out | handle<socket> | |
| 3 | binary_path | string | |
| 4 | argv | vector<string> | |
| 5 | environ | vector<string> | |
| 6 | window_size | ConsoleWindowSize | 
ControllerVsockConnectRequest 资源
在 fuchsia.starnix.container/controller.fidl 中定义
| Ordinal | 字段 | 类型 | 说明 | 
|---|---|---|---|
| 1 | port | uint32 | |
| 2 | bridge_socket | handle<socket> | 
Controller_GetJobHandle_Response 资源
在 fuchsia.starnix.container/controller.fidl 中定义
| Ordinal | 字段 | 类型 | 说明 | 
|---|---|---|---|
| 1 | job | handle<job> | 
Controller_GetVmoReferences_Response
在 fuchsia.starnix.container/controller.fidl 中定义
| Ordinal | 字段 | 类型 | 说明 | 
|---|---|---|---|
| 1 | references | vector<VmoReference> | 
SocketTunnelOpenSocketRequest
在 fuchsia.starnix.container/socket_tunnel.fidl 中定义
| Ordinal | 字段 | 类型 | 说明 | 
|---|---|---|---|
| 1 | socket_label | string | 
SocketTunnel_OpenSocket_Response 资源
在 fuchsia.starnix.container/socket_tunnel.fidl 中定义
| Ordinal | 字段 | 类型 | 说明 | 
|---|---|---|---|
| 1 | client_socket | handle<socket> | 
VmoReference
在 fuchsia.starnix.container/controller.fidl 中定义
| Ordinal | 字段 | 类型 | 说明 | 
|---|---|---|---|
| 1 | process_name | string | 包含由 vmo 支持的文件的进程的名称。 | 
| 2 | pid | uint64 | 包含由 vmo 支持的文件的进程的 Starnix pid。 | 
| 3 | fd | int32 | 进程中引用该 vmo 的文件描述符编号。 | 
| 4 | koid | uint64 | 这个视频 | 
联合体
Controller_GetJobHandle_Result 严格的 资源
在 fuchsia.starnix.container/controller.fidl 中定义
| Ordinal | 变体 | 类型 | 说明 | 
|---|---|---|---|
| 1 | response | Controller_GetJobHandle_Response | |
| 3 | framework_err | internal | 
Controller_GetVmoReferences_Result 严格
在 fuchsia.starnix.container/controller.fidl 中定义
| Ordinal | 变体 | 类型 | 说明 | 
|---|---|---|---|
| 1 | response | Controller_GetVmoReferences_Response | |
| 3 | framework_err | internal | 
Controller_SpawnConsole_Result 严格
在 fuchsia.starnix.container/controller.fidl 中定义
| Ordinal | 变体 | 类型 | 说明 | 
|---|---|---|---|
| 1 | response | Controller_SpawnConsole_Response | |
| 2 | err | SpawnConsoleError | |
| 3 | framework_err | internal | 
SocketTunnel_OpenSocket_Result 严格 资源
在 fuchsia.starnix.container/socket_tunnel.fidl 中定义
| Ordinal | 变体 | 类型 | 说明 | 
|---|---|---|---|
| 1 | response | SocketTunnel_OpenSocket_Response | |
| 3 | framework_err | internal | 
服务
SocketTunnelService
在 fuchsia.starnix.container/socket_tunnel.fidl 中定义
| 名称 | 类型 | 传输 | 
|---|---|---|
| socket_tunnel | fuchsia.starnix.container/SocketTunnel | 频道 |