Nanocl Daemon (v0.18.1)
Nanocl Daemon 是 HTTP REST API。
此 API 由 Nanocl Client 使用,所以 Nanocl Client 能执行的所有操作,也都能通过 API 完成。
大多数客户端命令直接对应 API 端点,例如 nanocl ps 对应 GET /processes。
一个明显例外是运行 Cargo,它由多次 API 调用组成。
本 API 按照 W3C 规范实现跨源资源共享(CORS)。
允许浏览器进行跨域通信。
所有响应使用通配的来源许可,因此完全公开,任何人以及任何网站上的代码都能访问。
使用可选过滤条件列出 Cargo。
query Parameters
| filter | string 示例: filter={ "filter": { "where": { "name": { "eq": "test" } } } } 通用过滤器。 |
| namespace | string 可选命名空间过滤器;省略或为空时返回全部命名空间。 |
响应
响应示例
- 200
[- {
- "NamespaceName": "string",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}
}
]根据规格创建新 Cargo。
query Parameters
| namespace | string 创建 Cargo 的命名空间,默认为 'global'。 |
Request Body schema: application/jsonrequired
required | 数组元素类型 objects (ContainerSpec) 每个 Cargo 副本中的应用容器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Dns | 数组元素类型 strings or null 分配给 Cargo 网络所有者的 DNS 服务器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Hostname | string or null 分配给 Cargo 网络所有者的 Docker 主机名。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
数组元素类型 objects (ContainerSpec) 按声明顺序在应用容器之前执行的初始化容器。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
object Cargo 的用户定义元数据。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Name required | string Cargo 名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoNetworkMode (string) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoPlacementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or HashMap (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Replicas | integer >= 1 默认值: 1 持久化 Cargo 副本数。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoResourceRequirementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Secrets | 数组元素类型 strings 由所有普通容器和初始化容器继承的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
响应
请求示例
- Payload
{- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}响应示例
- 201
- 409
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}
}将 Cargo 恢复到指定历史记录。
path Parameters
| cargo_key required | string 规范 Cargo 键,格式为 |
| history_key required | string Cargo 历史记录键。 |
响应
响应示例
- 200
- 404
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}
}用新规格更新 Cargo,并创建历史记录。
path Parameters
| key required | string 规范 Cargo 键,格式为 |
Request Body schema: application/jsonrequired
required | 数组元素类型 objects (ContainerSpec) 每个 Cargo 副本中的应用容器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Dns | 数组元素类型 strings or null 分配给 Cargo 网络所有者的 DNS 服务器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Hostname | string or null 分配给 Cargo 网络所有者的 Docker 主机名。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
数组元素类型 objects (ContainerSpec) 按声明顺序在应用容器之前执行的初始化容器。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
object Cargo 的用户定义元数据。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Name required | string Cargo 名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoNetworkMode (string) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoPlacementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or HashMap (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Replicas | integer >= 1 默认值: 1 持久化 Cargo 副本数。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoResourceRequirementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Secrets | 数组元素类型 strings 由所有普通容器和初始化容器继承的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
响应
请求示例
- Payload
{- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}响应示例
- 200
- 404
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}
}按规范键更新 Cargo,并添加历史记录。
path Parameters
| key required | string 规范 Cargo 键,格式为 |
Request Body schema: application/jsonrequired
数组元素类型 objects or null (ContainerSpec) 替换的应用容器声明。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Dns | 数组元素类型 strings or null Cargo 网络所有者的替换 DNS 服务器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Hostname | string or null Cargo 网络所有者的新 Docker 主机名。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
数组元素类型 objects or null (ContainerSpec) 替换的有序初始化容器声明。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
object Cargo 的新用户定义元数据。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Name | string or null Cargo 的新名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoNetworkMode (string) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoPlacementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or HashMap (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Replicas | integer or null >= 1 新副本数。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoResourceRequirementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Secrets | 数组元素类型 strings or null 替换的 Cargo 层共享 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
响应
请求示例
- Payload
{- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}响应示例
- 200
- 404
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}
}响应示例
- 200
- 404
[- {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}
]响应示例
- 200
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}, - "Instances": [
- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}
]
}使用可选过滤条件列出事件。
query Parameters
| filter | string 示例: filter={ "filter": { "where": { "kind": { "eq": "normal" } } } } 通用过滤器。 |
响应
响应示例
- 200
[- {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ExpiresAt": "2019-08-24T14:15:22Z",
- "ReportingNode": "string",
- "ReportingController": "string",
- "Kind": "error",
- "Action": "string",
- "Reason": "string",
- "Note": "string",
- "Actor": { },
- "Related": { },
- "Metadata": {
- "property1": "string",
- "property2": "string"
}
}
]监听所有对等节点的新事件,可选停止流的条件。
Request Body schema: application/json
required | 数组元素类型 strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or objects (NativeEventAction) |
| ActorKey | string or null |
null or EventActorKind (string) | |
| Kind required | 数组元素类型 strings (EventKind) 允许的元素 枚举值: "error" "normal" "warning" |
| RelatedKey | string or null |
null or EventActorKind (string) |
响应
请求示例
- Payload
[- {
- "ActorKey": "string",
- "ActorKind": { },
- "RelatedKey": "string",
- "RelatedKind": { },
- "Kind": [
- "error"
], - "Action": [
- "create"
]
}
]响应示例
- 200
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ExpiresAt": "2019-08-24T14:15:22Z",
- "ReportingNode": "string",
- "ReportingController": "string",
- "Kind": "error",
- "Action": "string",
- "Reason": "string",
- "Note": "string",
- "Actor": { },
- "Related": { },
- "Metadata": {
- "property1": "string",
- "property2": "string"
}
}使用可选过滤条件列出任务。
query Parameters
| filter | string 示例: filter={ "filter": { "where": { "name": { "eq": "job-example" } } } } 通用过滤器。 |
响应
响应示例
- 200
[- {
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "InstanceTotal": 0,
- "InstanceSuccess": 0,
- "InstanceRunning": 0,
- "InstanceFailed": 0,
- "Spec": {
- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}
}
]创建新任务。
Request Body schema: application/jsonrequired
required | 数组元素类型 objects (Config) 要运行的容器列表。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or ImagePullPolicy (string) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ImagePullSecret | string or null 拉取镜像时使用的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
object 用户定义的元数据。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Name required | string 任务名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Schedule | string or null 五字段 cron 表达式或支持的快捷形式;参见 [ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Secrets | 数组元素类型 strings or null 作为环境变量加载的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Ttl | integer or null >= 0 执行完成 x 秒后移除任务。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
响应
请求示例
- Payload
{- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}响应示例
- 201
- 409
{- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}
}响应示例
- 200
{- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "InstanceTotal": 0,
- "InstanceSuccess": 0,
- "InstanceRunning": 0,
- "InstanceFailed": 0,
- "Spec": {
- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}, - "Instances": [
- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}
]
}使用可选过滤条件列出指标。
query Parameters
| filter | string 示例: filter={ "filter": { "where": { "kind": { "eq": "CPU" } } } } 通用过滤器。 |
响应
响应示例
- 200
[- {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ExpiresAt": "2019-08-24T14:15:22Z",
- "NodeName": "string",
- "Kind": "string",
- "Data": null,
- "Note": "string"
}
]创建新指标。
Request Body schema: application/jsonrequired
| Data required | any 指标数据。 |
| Kind required | string 指标类型。 |
| Note | string or null 指标的可选备注。 |
响应
请求示例
- Payload
{- "Kind": "string",
- "Data": null,
- "Note": "string"
}响应示例
- 201
- 409
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ExpiresAt": "2019-08-24T14:15:22Z",
- "NodeName": "string",
- "Kind": "string",
- "Data": null,
- "Note": "string"
}响应示例
- 200
- 404
[- {
- "Name": "string",
- "Cargoes": [
- {
- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}, - "Instances": [
- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}
]
}
]
}
]列出持久化的节点级 Docker 网络快照。
query Parameters
| filter | string 示例: filter={ "where": { "node_name": { "eq": "node-a" } } } 通用过滤器。 |
响应
响应示例
- 200
[- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "NodeName": "string",
- "Data": {
- "Name": "string",
- "Id": "string",
- "Created": { },
- "Scope": "string",
- "Driver": "string",
- "EnableIPv6": true,
- "IPAM": { },
- "Internal": true,
- "Attachable": true,
- "Ingress": true,
- "Containers": {
- "property1": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}, - "property2": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}
}, - "Options": {
- "property1": "string",
- "property2": "string"
}, - "Labels": {
- "property1": "string",
- "property2": "string"
}
}, - "Metadata": null
}
]响应示例
- 200
- 404
{- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "NodeName": "string",
- "Data": {
- "Name": "string",
- "Id": "string",
- "Created": { },
- "Scope": "string",
- "Driver": "string",
- "EnableIPv6": true,
- "IPAM": { },
- "Internal": true,
- "Attachable": true,
- "Ingress": true,
- "Containers": {
- "property1": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}, - "property2": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}
}, - "Options": {
- "property1": "string",
- "property2": "string"
}, - "Labels": {
- "property1": "string",
- "property2": "string"
}
}, - "Metadata": null
}在节点上启动 Cargo 实例,用于节点间通信。
Request Body schema: application/jsonrequired
| CargoKey required | string 规范 Cargo 键,格式为 | ||||
required | 数组元素类型 objects (CargoReplicaTask) 分配给此节点的具体持久化副本,按序号排序。 | ||||
Array
| |||||
响应
请求示例
- Payload
{- "CargoKey": "string",
- "Replicas": [
- {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Ordinal": 0
}
]
}使用可选过滤条件列出进程。
query Parameters
| filter | string 示例: filter={ "where": { "name": { "eq": "test" } } } 通用过滤器。 |
响应
响应示例
- 200
[- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}
]获取指定类型和规范资源键的进程日志。
path Parameters
| key required | string 示例: global.deploy-example 规范资源键,格式为 |
| kind required | string 示例: cargo 进程类型。 |
query Parameters
| follow | boolean 是否返回数据流的布尔值。 |
| since | integer <int64> 仅返回指定时间戳之后的日志。 |
| tail | string 仅返回最后 n 条日志(整数)或全部日志('all')。 |
| timestamps | boolean 为每行日志添加时间戳。 |
| until | integer <int64> 仅返回指定时间戳之前的日志。 |
响应
为具体进程名称或 ID 创建 exec 实例。
path Parameters
| name required | string 容器名称或 ID。 |
Request Body schema: application/jsonrequired
| AttachStderr | boolean or null 连接标准错误。 |
| AttachStdin | boolean or null 连接标准输入。 |
| AttachStdout | boolean or null 连接标准输出。 |
| Cmd | 数组元素类型 strings or null 要执行的命令及参数。 |
| DetachKeys | string or null 兼容 Docker 的分离按键序列。 |
| Env | 数组元素类型 strings or null 环境变量,格式为 |
| Privileged | boolean or null 以扩展权限运行命令。 |
| Tty | boolean or null 分配伪终端。 |
| User | string or null 命令使用的用户和可选用户组。 |
| WorkingDir | string or null 进程内部工作目录。 |
响应
请求示例
- Payload
{- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "Tty": true,
- "DetachKeys": "string",
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Privileged": true,
- "User": "string",
- "WorkingDir": "string"
}响应示例
- 201
- 404
{- "Id": "string"
}响应示例
- 200
- 404
{- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}列出资源类型。
query Parameters
| filter | string 示例: filter={ "filter": { "where": { "name": { "eq": "test" } } } } 通用过滤器。 |
响应
响应示例
- 200
[- {
- "Name": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Metadata": null,
- "Data": {
- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}
}
]创建资源类型。
Request Body schema: application/jsonrequired
required | object (ResourceKindSpec) 资源类型规格。 | ||||
| |||||
object 资源类型的用户定义元数据。 | |||||
| |||||
| Name required | string 资源类型名称。 | ||||
| Version required | string 资源类型版本。 | ||||
响应
请求示例
- Payload
{- "Name": "string",
- "Version": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}
}响应示例
- 201
- 409
{- "Name": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Metadata": null,
- "Data": {
- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}
}响应示例
- 200
- 404
{- "Name": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Versions": [
- {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "KindKey": "string",
- "Version": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}
}
]
}获取资源类型版本详细信息。
path Parameters
| domain required | string 资源类型的域名。 |
| name required | string 资源类型名称。 |
| version required | string 资源类型版本。 |
响应
响应示例
- 200
- 404
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "KindKey": "string",
- "Version": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}
}使用可选过滤条件列出资源。
query Parameters
| filter | string 示例: filter={ "filter": { "where": { "kind": { "eq": "ncproxy.io/rule" } } } } 通用过滤器。 |
响应
响应示例
- 200
[- {
- "Kind": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ResourceKey": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}
}
]创建新资源。
Request Body schema: application/jsonrequired
required | object 资源数据,JSON 对象。 | ||
| |||
| Kind required | string 资源类型。 | ||
object 资源的用户定义元数据。 | |||
| |||
| Name required | string 资源名称。 | ||
响应
请求示例
- Payload
{- "Name": "string",
- "Kind": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}响应示例
- 200
- 409
{- "Kind": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ResourceKey": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}
}创建新资源规格并添加历史记录。
path Parameters
| name required | string 资源名称。 |
Request Body schema: application/jsonrequired
required | object 以 JSON 对象表示的资源规格。 | ||
| |||
object 以 JSON 对象表示的资源元数据。 | |||
| |||
响应
请求示例
- Payload
{- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}响应示例
- 200
- 404
{- "Kind": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ResourceKey": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}
}响应示例
- 200
- 404
[- {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ResourceKey": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}
]响应示例
- 200
- 404
{- "Kind": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ResourceKey": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}
}响应示例
- 200
- 404
{- "Kind": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ResourceKey": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}
}使用可选过滤条件列出 Secret。
query Parameters
| filter | string 示例: filter={ "filter": { "where": { "kind": { "eq": "Env" } } } } 通用过滤器。 |
响应
响应示例
- 200
[- {
- "Name": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Kind": "string",
- "Immutable": true,
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}
]创建新 Secret。
Request Body schema: application/jsonrequired
required | object Secret 数据。 | ||
| |||
| Immutable | boolean 无法更新 Secret。 | ||
| Kind required | string Secret 类型。 | ||
object 资源的用户定义元数据。 | |||
| |||
| Name required | string Secret 名称。 | ||
响应
请求示例
- Payload
{- "Name": "string",
- "Kind": "string",
- "Immutable": true,
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}响应示例
- 200
- 409
{- "Name": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Kind": "string",
- "Immutable": true,
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}更新 Secret。
path Parameters
| key required | string Secret 键。 |
Request Body schema: application/jsonrequired
required | object 以 JSON 对象表示的 Secret 数据。 | ||
| |||
object Secret 的用户定义元数据。 | |||
| |||
响应
请求示例
- Payload
{- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}响应示例
- 200
- 404
{- "Name": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Kind": "string",
- "Immutable": true,
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}响应示例
- 200
- 404
{- "Name": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Kind": "string",
- "Immutable": true,
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}响应示例
- 200
{- "ID": "string",
- "Containers": 0,
- "ContainersRunning": 0,
- "ContainersPaused": 0,
- "ContainersStopped": 0,
- "Images": 0,
- "Driver": "string",
- "DriverStatus": [
- [
- "string"
]
], - "DockerRootDir": "string",
- "Plugins": { },
- "MemoryLimit": true,
- "SwapLimit": true,
- "KernelMemoryTCP": true,
- "CpuCfsPeriod": true,
- "CpuCfsQuota": true,
- "CPUShares": true,
- "CPUSet": true,
- "PidsLimit": true,
- "OomKillDisable": true,
- "IPv4Forwarding": true,
- "BridgeNfIptables": true,
- "BridgeNfIp6tables": true,
- "Debug": true,
- "NFd": 0,
- "NGoroutines": 0,
- "SystemTime": "string",
- "LoggingDriver": "string",
- "CgroupDriver": { },
- "CgroupVersion": { },
- "NEventsListener": 0,
- "KernelVersion": "string",
- "OperatingSystem": "string",
- "OSVersion": "string",
- "OSType": "string",
- "Architecture": "string",
- "NCPU": 0,
- "MemTotal": 0,
- "IndexServerAddress": "string",
- "RegistryConfig": { },
- "GenericResources": { },
- "HttpProxy": "string",
- "HttpsProxy": "string",
- "NoProxy": "string",
- "Name": "string",
- "Labels": [
- "string"
], - "ExperimentalBuild": true,
- "ServerVersion": "string",
- "Runtimes": {
- "property1": {
- "path": "string",
- "runtimeArgs": [
- "string"
], - "status": {
- "property1": "string",
- "property2": "string"
}
}, - "property2": {
- "path": "string",
- "runtimeArgs": [
- "string"
], - "status": {
- "property1": "string",
- "property2": "string"
}
}
}, - "DefaultRuntime": "string",
- "Swarm": { },
- "LiveRestoreEnabled": true,
- "Isolation": { },
- "InitBinary": "string",
- "ContainerdCommit": { },
- "RuncCommit": { },
- "InitCommit": { },
- "SecurityOptions": [
- "string"
], - "ProductLicense": "string",
- "DefaultAddressPools": [
- {
- "Base": "string",
- "Size": 0
}
], - "Warnings": [
- "string"
], - "CDISpecDirs": [
- "string"
], - "HostGateway": "string",
- "Network": {
- "Name": "string",
- "Id": "string",
- "Created": { },
- "Scope": "string",
- "Driver": "string",
- "EnableIPv6": true,
- "IPAM": { },
- "Internal": true,
- "Attachable": true,
- "Ingress": true,
- "Containers": {
- "property1": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}, - "property2": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}
}, - "Options": {
- "property1": "string",
- "property2": "string"
}, - "Labels": {
- "property1": "string",
- "property2": "string"
}
}, - "Config": {
- "hosts": [
- "string"
], - "state_dir": "string",
- "docker_host": "string",
- "store_addr": "string",
- "gateway": "string",
- "hostname": "string",
- "nodes": [
- "string"
], - "advertise_addr": "string",
- "conf_dir": "string",
- "gid": 0,
- "ssl": { }
}
}使用可选过滤条件列出虚拟机。
query Parameters
| filter | string 示例: filter={ "filter": { "where": { "name": { "eq": "my-vm" } } } } 通用过滤器。 |
| namespace | string 可选命名空间过滤器;省略或为空时返回全部命名空间。 |
响应
响应示例
- 200
[- {
- "NamespaceName": "string",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Version": "string",
- "VmKey": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "User": "string",
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": {
- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}
}
}
]创建虚拟机。
query Parameters
| namespace | string 虚拟机命名空间。 |
Request Body schema: application/jsonrequired
null or VmHostConfig (object) | |||
One of null | |||
| Hostname | string or null VM 主机名(默认:根据名称生成)。 | ||
| Image required | string VM 使用的镜像,必须提供完整路径,如 /var/lib/nanocl/vm/image.qcow2。 | ||
null or Config (object) | |||
One of null | |||
object or null 用户定义的键值元数据。 | |||
| |||
| MacAddress | string or null VM 的 MAC 地址(默认自动生成)。 | ||
object 用户定义的元数据。 | |||
| |||
| Name required | string VM 名称。 | ||
| Password | string or null VM 默认密码(默认:cloud)。 | ||
| SshKey | string or null 用户默认 SSH 公钥(推荐)。 | ||
| User | string or null VM 默认用户(默认:cloud)。 | ||
响应
请求示例
- Payload
{- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "User": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": { }
}响应示例
- 200
- 409
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Version": "string",
- "VmKey": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "User": "string",
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": {
- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}
}
}更新虚拟机配置,即合并当前配置和新配置,并添加历史记录。
path Parameters
| key required | string 规范 VM 键,格式为 |
Request Body schema: application/jsonrequired
null or VmHostConfig (object) | |||
One of null | |||
| Hostname | string or null VM 主机名。 | ||
null or Config (object) | |||
One of null | |||
object or null 用户定义的键值元数据。 | |||
| |||
object 用户定义的元数据。 | |||
| |||
| Name | string or null VM 名称。 | ||
| Password | string or null VM 默认密码(cloud)。 | ||
| SshKey | string or null 用户默认 SSH 密钥。 | ||
| User | string or null VM 默认用户(cloud)。 | ||
响应
请求示例
- Payload
{- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "User": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": { }
}响应示例
- 200
- 404
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Version": "string",
- "VmKey": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "User": "string",
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": {
- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}
}
}响应示例
- 200
- 404
[- {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Version": "string",
- "VmKey": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "User": "string",
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": {
- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}
}
]响应示例
- 200
- 404
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Version": "string",
- "VmKey": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "User": "string",
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": {
- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}
}, - "Instances": [
- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}
]
}| Addr | string or null IP 地址。 |
| PrefixLen | integer or null <int64> IP 地址掩码长度。 |
{- "Addr": "string",
- "PrefixLen": 0
}为 OpenApi 生成 Any 类型的辅助工具,适用于 ResourceSpec 等动态 JSON 对象。
{- "property1": "string",
- "property2": "string"
}| Arch required | string Arch 是当前二进制文件的架构。 |
| Channel required | string Channel 是当前二进制文件的发布通道。 |
| CommitId required | string CommitID 是当前二进制文件的提交 ID。 |
| Version required | string Version 是当前二进制文件版本。 |
{- "Arch": "string",
- "Channel": "string",
- "Version": "string",
- "CommitId": "string"
}数组元素类型 objects or null (BlkioStatsEntry) | |||||||||
Array
| |||||||||
数组元素类型 objects or null (BlkioStatsEntry) | |||||||||
Array
| |||||||||
数组元素类型 objects or null (BlkioStatsEntry) | |||||||||
Array
| |||||||||
数组元素类型 objects or null (BlkioStatsEntry) | |||||||||
Array
| |||||||||
数组元素类型 objects or null (BlkioStatsEntry) | |||||||||
Array
| |||||||||
数组元素类型 objects or null (BlkioStatsEntry) | |||||||||
Array
| |||||||||
数组元素类型 objects or null (BlkioStatsEntry) | |||||||||
Array
| |||||||||
数组元素类型 objects or null (BlkioStatsEntry) | |||||||||
Array
| |||||||||
{- "io_service_bytes_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_serviced_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_queue_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_service_time_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_wait_time_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_merged_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_time_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "sectors_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
]
}| major required | integer <int64> >= 0 |
| minor required | integer <int64> >= 0 |
| op required | string |
| value required | integer <int64> >= 0 |
{- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}required | object (CPUUsage) 容器 CPU 使用统计。 | ||||||||
| |||||||||
| online_cpus | integer or null <int64> >= 0 | ||||||||
| system_cpu_usage | integer or null <int64> >= 0 | ||||||||
required | object (ThrottlingData) CPU 节流统计。 | ||||||||
| |||||||||
{- "cpu_usage": {
- "percpu_usage": [
- 0
], - "usage_in_usermode": 0,
- "total_usage": 0,
- "usage_in_kernelmode": 0
}, - "system_cpu_usage": 0,
- "online_cpus": 0,
- "throttling_data": {
- "periods": 0,
- "throttled_periods": 0,
- "throttled_time": 0
}
}| percpu_usage | 数组元素类型 integers or null <int64> [ items <int64 > >= 0 ] |
| total_usage required | integer <int64> >= 0 |
| usage_in_kernelmode required | integer <int64> >= 0 |
| usage_in_usermode required | integer <int64> >= 0 |
{- "percpu_usage": [
- 0
], - "usage_in_usermode": 0,
- "total_usage": 0,
- "usage_in_kernelmode": 0
}| CreatedAt required | string <date-time> Cargo 创建时间。 | ||||||||||||||||||||||||||||||||
| NamespaceName required | string 命名空间名称。 | ||||||||||||||||||||||||||||||||
required | object (CargoSpecRevision) Cargo 规格。 | ||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||
required | object (ObjPsStatus) Cargo 状态。 | ||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}
}| CreatedAt required | string <date-time> Cargo 创建时间。 | ||||||||||||||||||||||||||||||||
| InstanceRunning required | integer >= 0 运行实例数。 | ||||||||||||||||||||||||||||||||
required | 数组元素类型 objects (Process) 实例列表。 | ||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||
| InstanceTotal required | integer >= 0 实例数量。 | ||||||||||||||||||||||||||||||||
| NamespaceName required | string 命名空间名称。 | ||||||||||||||||||||||||||||||||
required | object (CargoSpecRevision) Cargo 规格。 | ||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||
required | object (ObjPsStatus) Cargo 状态。 | ||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}, - "Instances": [
- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}
]
}Cargo 使用的 Docker 网络模式。
除了内置模式,Docker 接受任何非空网络名称。Nanocl 保留 container:<id>,因为用户不能直接加入由容器拥有的网络命名空间。
"string"| Cargoes | 数组元素类型 strings or null 根据节点上运行的 Cargo 选择。 | ||||||
数组元素类型 objects or null (NodeConstraint) 可选高级约束(键、运算符、值)。 | |||||||
Array
| |||||||
| Groups | 数组元素类型 strings or null 按组选择。 | ||||||
| Labels | 数组元素类型 strings or null 按标签选择。 | ||||||
| Regions | 数组元素类型 strings or null 按区域选择。 | ||||||
| Vms | 数组元素类型 strings or null 根据节点上运行的 VM 选择。 | ||||||
{- "Labels": [
- "string"
], - "Regions": [
- "string"
], - "Groups": [
- "string"
], - "Cargoes": [
- "string"
], - "Vms": [
- "string"
], - "Constraints": [
- {
- "Key": "string",
- "Operator": "Eq",
- "Value": "string"
}
]
}null or CargoPlacementSelectorSpec (object) | |
One of null | |
| Regions | 数组元素类型 strings or null 部署 Cargo 的区域。 |
null or CargoPlacementSelectorSpec (object) | |
One of null | |
null or (CargoPlacementStrategy (CargoPlacementStrategy (string) or CargoPlacementStrategy (string) or CargoPlacementStrategy (string) or CargoPlacementStrategy (object))) | |
One of null | |
{- "Strategy": { },
- "Regions": [
- "string"
], - "Require": { },
- "Prefer": { }
}用于定义如何将 Cargo 放置到节点的策略枚举。
{- "UserDefined": "string"
}| Key required | string <uuid> 稳定且持久化的 Cargo 副本标识。 |
| Ordinal required | integer <int32> 副本在 Cargo 内稳定的序号。 |
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Ordinal": 0
}| CpuCores | integer or null >= 0 所需 CPU 核数。 |
| CpuUtilizationCap | number or null <float> 目标节点允许的最大平均 CPU 使用率(0.0 到 1.0)。 |
| CpuWeight | number or null <float> 平衡放置策略中的可选 CPU 权重(0.0 到 1.0)。 |
| MemoryBytes | integer or null >= 0 所需内存,单位字节。 |
| MemoryUtilizationCap | number or null <float> 目标节点允许的最大平均内存使用率(0.0 到 1.0)。 |
| MemoryWeight | number or null <float> 平衡放置策略中的可选内存权重(0.0 到 1.0)。 |
| StorageBytes | integer or null >= 0 所需存储空间,单位字节。 |
{- "CpuCores": 0,
- "CpuUtilizationCap": 0,
- "MemoryBytes": 0,
- "MemoryUtilizationCap": 0,
- "CpuWeight": 0,
- "MemoryWeight": 0,
- "StorageBytes": 0
}required | 数组元素类型 objects (ContainerSpec) 每个 Cargo 副本中的应用容器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Dns | 数组元素类型 strings or null 分配给 Cargo 网络所有者的 DNS 服务器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Hostname | string or null 分配给 Cargo 网络所有者的 Docker 主机名。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
数组元素类型 objects (ContainerSpec) 按声明顺序在应用容器之前执行的初始化容器。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
object Cargo 的用户定义元数据。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Name required | string Cargo 名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoNetworkMode (string) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoPlacementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or HashMap (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Replicas | integer >= 1 默认值: 1 持久化 Cargo 副本数。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoResourceRequirementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Secrets | 数组元素类型 strings 由所有普通容器和初始化容器继承的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}数组元素类型 objects or null (ContainerSpec) 替换的应用容器声明。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Dns | 数组元素类型 strings or null Cargo 网络所有者的替换 DNS 服务器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Hostname | string or null Cargo 网络所有者的新 Docker 主机名。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
数组元素类型 objects or null (ContainerSpec) 替换的有序初始化容器声明。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
object Cargo 的新用户定义元数据。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Name | string or null Cargo 的新名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoNetworkMode (string) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoPlacementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or HashMap (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Replicas | integer or null >= 1 新副本数。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoResourceRequirementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Secrets | 数组元素类型 strings or null 替换的 Cargo 层共享 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}| CargoKey required | string 规范 Cargo 键,格式为 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | 数组元素类型 objects (ContainerSpec) 每个 Cargo 副本中的应用容器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| CreatedAt required | string <date-time> Cargo 规格创建时间。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Dns | 数组元素类型 strings or null 分配给 Cargo 网络所有者的 DNS 服务器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Hostname | string or null 分配给 Cargo 网络所有者的 Docker 主机名。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
数组元素类型 objects (ContainerSpec) 按声明顺序执行的初始化容器。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Key required | string <uuid> Cargo 规格唯一标识。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
object Cargo 的用户定义元数据。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Name required | string Cargo 名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoNetworkMode (string) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoPlacementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or HashMap (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Replicas | integer >= 1 默认值: 1 持久化 Cargo 副本数。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or CargoResourceRequirementSpec (object) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Secrets | 数组元素类型 strings 由所有普通容器和初始化容器继承的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Version required | string 规格版本。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}| CreatedAt required | string <date-time> Cargo 创建时间。 | ||||||||||||||||||||||||||||||||
| InstanceRunning required | integer >= 0 运行实例数。 | ||||||||||||||||||||||||||||||||
| InstanceTotal required | integer >= 0 实例数量。 | ||||||||||||||||||||||||||||||||
| NamespaceName required | string 命名空间名称。 | ||||||||||||||||||||||||||||||||
required | object (CargoSpecRevision) Cargo 规格。 | ||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||
required | object (ObjPsStatus) Cargo 状态。 | ||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||
{- "NamespaceName": "string",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}
}null or String (string) | |
One of null | |
| DataPathPort | integer or null <int32> >= 0 DataPathPort 指定数据流量的数据路径端口,允许范围为 1024 到 49151。未设置或设为 0 时,使用默认端口 4789。 |
| DefaultAddrPool | 数组元素类型 strings or null Default Address Pool 指定全局作用域网络的默认子网池。 |
| ID | string or null Swarm ID。 |
| RootRotationInProgress | boolean or null Swarm 是否正在轮换根 CA。 |
null or SwarmSpec (object) | |
One of null | |
| SubnetSize | integer or null <int32> >= 0 SubnetSize 指定从默认子网池创建网络时的子网大小。 |
null or TlsInfo (object) | |
One of null | |
null or String (string) | |
One of null | |
null or ObjectVersion (object) | |
One of null | |
{- "ID": "string",
- "Version": { },
- "CreatedAt": { },
- "UpdatedAt": { },
- "Spec": { },
- "TLSInfo": { },
- "RootRotationInProgress": true,
- "DataPathPort": 0,
- "DefaultAddrPool": [
- "string"
], - "SubnetSize": 0
}| Expected | string or null dockerd 在构建时设置的预期外部工具提交 ID。 |
| ID | string or null 外部工具的实际提交 ID。 |
{- "ID": "string",
- "Expected": "string"
}| ArgsEscaped | boolean or null 命令已转义(仅限 Windows)。 | ||
| AttachStderr | boolean or null 是否连接 | ||
| AttachStdin | boolean or null 是否连接 | ||
| AttachStdout | boolean or null 是否连接 | ||
| Cmd | 数组元素类型 strings or null 要运行的命令,指定为字符串或字符串数组。 | ||
| Domainname | string or null 容器使用的域名。 | ||
| Entrypoint | 数组元素类型 strings or null 容器入口点,指定为字符串或字符串数组。如果数组仅包含一个空字符串( | ||
| Env | 数组元素类型 strings or null 在容器内设置的环境变量列表,格式为 | ||
object or null 将端口映射到空对象的对象,格式为 | |||
| |||
null or HealthConfig (object) | |||
One of null | |||
null or HostConfig (object) | |||
One of null | |||
| Hostname | string or null 容器主机名,必须符合 RFC 1123。 | ||
| Image | string or null 创建容器时使用的镜像名称。 | ||
object or null 用户定义的键值元数据。 | |||
| |||
| MacAddress | string or null 容器 MAC 地址。 | ||
| NetworkDisabled | boolean or null 禁用容器网络。 | ||
null or NetworkingConfig_String (object) | |||
One of null | |||
| OnBuild | 数组元素类型 strings or null
| ||
| OpenStdin | boolean or null 打开 | ||
| Shell | 数组元素类型 strings or null
| ||
| StdinOnce | boolean or null 一个已连接客户端断开后关闭 | ||
| StopSignal | string or null 停止容器的信号,指定为字符串或无符号整数。 | ||
| StopTimeout | integer or null <int64> 停止容器的超时,单位秒。 | ||
| Tty | boolean or null 将标准流连接到 TTY,包括尚未关闭的 | ||
| User | string or null 容器内执行命令的用户。 | ||
object or null 将容器内挂载点路径映射到空对象的对象。 | |||
| |||
| WorkingDir | string or null 命令运行的工作目录。 | ||
{- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}| ArgsEscaped | boolean or null 命令已转义(仅限 Windows)。 | ||
| AttachStderr | boolean or null 是否连接 | ||
| AttachStdin | boolean or null 是否连接 | ||
| AttachStdout | boolean or null 是否连接 | ||
| Cmd | 数组元素类型 strings or null 要运行的命令,指定为字符串或字符串数组。 | ||
| Domainname | string or null 容器使用的域名。 | ||
| Entrypoint | 数组元素类型 strings or null 容器入口点,指定为字符串或字符串数组。如果数组仅包含一个空字符串( | ||
| Env | 数组元素类型 strings or null 在容器内设置的环境变量列表,格式为 | ||
object or null 将端口映射到空对象的对象,格式为 | |||
| |||
null or HealthConfig (object) | |||
One of null | |||
| Hostname | string or null 容器主机名,必须符合 RFC 1123。 | ||
| Image | string or null 创建容器时使用的镜像名称或引用,或此容器创建时使用的镜像。 | ||
object or null 用户定义的键值元数据。 | |||
| |||
| MacAddress | string or null 容器 MAC 地址。已弃用:此字段在 API v1.44 及以上弃用,请改用 EndpointSettings.MacAddress。 | ||
| NetworkDisabled | boolean or null 禁用容器网络。 | ||
| OnBuild | 数组元素类型 strings or null
| ||
| OpenStdin | boolean or null 打开 | ||
| Shell | 数组元素类型 strings or null
| ||
| StdinOnce | boolean or null 一个已连接客户端断开后关闭 | ||
| StopSignal | string or null 停止容器的信号,指定为字符串或无符号整数。 | ||
| StopTimeout | integer or null <int64> 停止容器的超时,单位秒。 | ||
| Tty | boolean or null 将标准流连接到 TTY,包括尚未关闭的 | ||
| User | string or null 容器内执行命令的用户。 | ||
object or null 将容器内挂载点路径映射到空对象的对象。 | |||
| |||
| WorkingDir | string or null 命令运行的工作目录。 | ||
{- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
]
}| AppArmorProfile | string or null | ||||||||||||||||
| Args | 数组元素类型 strings or null 正在运行命令的参数。 | ||||||||||||||||
null or ContainerConfig (object) | |||||||||||||||||
One of null | |||||||||||||||||
| Created | string or null 容器创建时间。 | ||||||||||||||||
| Driver | string or null | ||||||||||||||||
| ExecIDs | 数组元素类型 strings or null 容器中运行的 exec 实例 ID。 | ||||||||||||||||
null or GraphDriverData (object) | |||||||||||||||||
One of null | |||||||||||||||||
null or HostConfig (object) | |||||||||||||||||
One of null | |||||||||||||||||
| HostnamePath | string or null | ||||||||||||||||
| HostsPath | string or null | ||||||||||||||||
| Id | string or null 容器 ID。 | ||||||||||||||||
| Image | string or null 容器镜像 ID。 | ||||||||||||||||
| LogPath | string or null | ||||||||||||||||
| MountLabel | string or null | ||||||||||||||||
数组元素类型 objects or null (MountPoint) | |||||||||||||||||
Array
| |||||||||||||||||
| Name | string or null | ||||||||||||||||
null or NetworkSettings (object) | |||||||||||||||||
One of null | |||||||||||||||||
| Path | string or null 正在运行命令的路径。 | ||||||||||||||||
| Platform | string or null | ||||||||||||||||
| ProcessLabel | string or null | ||||||||||||||||
| ResolvConfPath | string or null | ||||||||||||||||
| RestartCount | integer or null <int64> | ||||||||||||||||
| SizeRootFs | integer or null <int64> 容器中全部文件总大小。 | ||||||||||||||||
| SizeRw | integer or null <int64> 容器创建或修改的文件大小。 | ||||||||||||||||
null or ContainerState (object) | |||||||||||||||||
One of null | |||||||||||||||||
{- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}| ArgsEscaped | boolean or null 命令已转义(仅限 Windows)。 | ||
| AttachStderr | boolean or null 是否连接 | ||
| AttachStdin | boolean or null 是否连接 | ||
| AttachStdout | boolean or null 是否连接 | ||
| Cmd | 数组元素类型 strings or null 要运行的命令,指定为字符串或字符串数组。 | ||
| Domainname | string or null 容器使用的域名。 | ||
| Entrypoint | 数组元素类型 strings or null 容器入口点,指定为字符串或字符串数组。如果数组仅包含一个空字符串( | ||
| Env | 数组元素类型 strings or null 在容器内设置的环境变量列表,格式为 | ||
| Essential | boolean 默认值: true 此容器失败是否让 Cargo 副本不健康。 | ||
object or null 将端口映射到空对象的对象,格式为 | |||
| |||
null or ContainerSpecHealthConfig (object) | |||
One of null | |||
null or ContainerSpecHostConfig (object) | |||
One of null | |||
| Hostname | string or null 容器主机名,必须符合 RFC 1123。 | ||
| Image | string or null 创建容器时使用的镜像名称。 | ||
| ImagePullPolicy | string 默认值: "IfNotPresent" 枚举值: "Never" "Always" "IfNotPresent" 拉取此容器镜像的策略。 | ||
null or string 拉取此容器镜像时使用的 Secret。 | |||
One of null 拉取此容器镜像时使用的 Secret。 | |||
object or null 用户定义的键值元数据。 | |||
| |||
| MacAddress | string or null 容器 MAC 地址。 | ||
| Name required | string 在 Cargo 声明中唯一的名称。 | ||
| NetworkDisabled | boolean or null 禁用容器网络。 | ||
null or ContainerSpecNetworkingConfig_String (object) | |||
One of null | |||
| OnBuild | 数组元素类型 strings or null
| ||
| OpenStdin | boolean or null 打开 | ||
| Secrets | 数组元素类型 strings 默认值: [] 仅注入此容器的 Secret。 | ||
| Shell | 数组元素类型 strings or null
| ||
| StdinOnce | boolean or null 一个已连接客户端断开后关闭 | ||
| StopSignal | string or null 停止容器的信号,指定为字符串或无符号整数。 | ||
| StopTimeout | integer or null <int64> 停止容器的超时,单位秒。 | ||
| Tty | boolean or null 将标准流连接到 TTY,包括尚未关闭的 | ||
| User | string or null 容器内执行命令的用户。 | ||
object or null 将容器内挂载点路径映射到空对象的对象。 | |||
| |||
| WorkingDir | string or null 命令运行的工作目录。 | ||
{- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}| CgroupPermissions | string or null |
| PathInContainer | string or null |
| PathOnHost | string or null |
{- "PathOnHost": "string",
- "PathInContainer": "string",
- "CgroupPermissions": "string"
}| Capabilities | 数组元素类型 strings or null[ items ] 权限能力列表,由多个“与”能力列表以“或”关系组成。 | ||
| Count | integer or null <int64> | ||
| DeviceIDs | 数组元素类型 strings or null | ||
| Driver | string or null | ||
object or null 驱动专属选项,以键值对指定,直接传递给驱动。 | |||
| |||
{- "Driver": "string",
- "Count": 0,
- "DeviceIDs": [
- "string"
], - "Capabilities": [
- [
- "string"
]
], - "Options": {
- "property1": "string",
- "property2": "string"
}
}| IPv4Address | string or null |
| IPv6Address | string or null |
| LinkLocalIPs | 数组元素类型 strings or null |
{- "IPv4Address": "string",
- "IPv6Address": "string",
- "LinkLocalIPs": [
- "string"
]
}| Aliases | 数组元素类型 strings or null | ||
| DNSNames | 数组元素类型 strings or null 端点在指定网络上的全部 DNS 名称,来自容器名称、网络别名、容器短 ID 和主机名。名称不是完全限定名称,但可包含多个点。添加 | ||
object or null DriverOpts 是驱动选项和值的映射,直接传递给驱动,内容由具体驱动决定。 | |||
| |||
| EndpointID | string or null 沙箱中服务端点的唯一 ID。 | ||
| Gateway | string or null 此网络的网关地址。 | ||
| GlobalIPv6Address | string or null 全局 IPv6 地址。 | ||
| GlobalIPv6PrefixLen | integer or null <int64> 全局 IPv6 地址掩码长度。 | ||
| IPAddress | string or null IPv4 地址。 | ||
null or ContainerSpecEndpointIpamConfig (object) | |||
One of null | |||
| IPPrefixLen | integer or null <int64> IPv4 地址掩码长度。 | ||
| IPv6Gateway | string or null IPv6 网关地址。 | ||
| Links | 数组元素类型 strings or null | ||
| MacAddress | string or null 端点在此网络上的 MAC 地址,网络驱动可能忽略此参数。 | ||
| NetworkID | string or null 网络唯一 ID。 | ||
{- "IPAMConfig": { },
- "Links": [
- "string"
], - "MacAddress": "string",
- "Aliases": [
- "string"
], - "NetworkID": "string",
- "EndpointID": "string",
- "Gateway": "string",
- "IPAddress": "string",
- "IPPrefixLen": 0,
- "IPv6Gateway": "string",
- "GlobalIPv6Address": "string",
- "GlobalIPv6PrefixLen": 0,
- "DriverOpts": {
- "property1": "string",
- "property2": "string"
}, - "DNSNames": [
- "string"
]
}additional property | null or 数组元素类型 objects |
One of null | |
{- "property1": { },
- "property2": { }
}| Interval | integer or null <int64> 检查之间的等待时间,单位纳秒。应为 0 或至少 1000000(1 毫秒),0 表示继承。 |
| Retries | integer or null <int64> 将容器视为不健康所需的连续失败次数,0 表示继承。 |
| StartInterval | integer or null <int64> 启动宽限期内检查之间的等待时间,单位纳秒。应为 0 或至少 1000000(1 毫秒),0 表示继承。 |
| StartPeriod | integer or null <int64> 容器初始化的启动宽限期,在此期间不开始健康检查重试倒计时,单位纳秒。应为 0 或至少 1000000(1 毫秒),0 表示继承。 |
| Test | 数组元素类型 strings or null 要执行的测试,可选值: |
| Timeout | integer or null <int64> 判定检查卡住之前的等待时间,应为 0 或至少 1000000(1 毫秒),0 表示继承。 |
{- "Test": [
- "string"
], - "Interval": 0,
- "Timeout": 0,
- "Retries": 0,
- "StartPeriod": 0,
- "StartInterval": 0
}object or null 附加到容器的任意非标识元数据,在容器启动时提供给运行时。 | |||||||||||||||||
| |||||||||||||||||
| AutoRemove | boolean or null 容器进程退出时自动移除容器。设置 | ||||||||||||||||
| Binds | 数组元素类型 strings or null 容器的卷绑定列表,每项是以下格式之一的字符串:
| ||||||||||||||||
数组元素类型 objects or null (ContainerSpecThrottleDevice) 限制设备读取速率(每秒字节数),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
数组元素类型 objects or null (ContainerSpecThrottleDevice) 限制设备读取速率(每秒 IO 次数),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
数组元素类型 objects or null (ContainerSpecThrottleDevice) 限制设备写入速率(每秒字节数),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
数组元素类型 objects or null (ContainerSpecThrottleDevice) 限制设备写入速率(每秒 IO 次数),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
| BlkioWeight | integer or null <int32> >= 0 块 IO 权重(相对权重)。 | ||||||||||||||||
数组元素类型 objects or null (ContainerSpecResourcesBlkioWeightDevice) 块 IO 权重(相对设备权重),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
| CapAdd | 数组元素类型 strings or null 要添加到容器的内核权限能力列表,与 'Capabilities' 选项冲突。 | ||||||||||||||||
| CapDrop | 数组元素类型 strings or null 要从容器移除的内核权限能力列表,与 'Capabilities' 选项冲突。 | ||||||||||||||||
| Cgroup | string or null 容器使用的 cgroup。 | ||||||||||||||||
null or ContainerSpecHostConfigCgroupnsModeEnum (string) | |||||||||||||||||
One of null | |||||||||||||||||
| CgroupParent | string or null
| ||||||||||||||||
| ConsoleSize | 数组元素类型 integers or null <int32> [ items <int32 > ] 初始控制台大小,以 | ||||||||||||||||
| ContainerIDFile | string or null 写入容器 ID 的文件路径。 | ||||||||||||||||
| CpuCount | integer or null <int64> 可用 CPU 数量,仅限 Windows。Windows Server 容器的处理器资源控制互斥,优先级依次为 | ||||||||||||||||
| CpuPercent | integer or null <int64> 可用 CPU 的使用比例,仅限 Windows。Windows Server 容器的处理器资源控制互斥,优先级依次为 | ||||||||||||||||
| CpuPeriod | integer or null <int64> CPU 周期长度,单位微秒。 | ||||||||||||||||
| CpuQuota | integer or null <int64> 容器在一个 CPU 周期内可获得的 CPU 时间,单位微秒。 | ||||||||||||||||
| CpuRealtimePeriod | integer or null <int64> CPU 实时周期长度,单位微秒。设为 0 时不给实时任务分配时间。 | ||||||||||||||||
| CpuRealtimeRuntime | integer or null <int64> CPU 实时运行时间长度,单位微秒。设为 0 时不给实时任务分配时间。 | ||||||||||||||||
| CpusetCpus | string or null 允许执行的 CPU(如 | ||||||||||||||||
| CpusetMems | string or null 允许执行的内存节点 MEM(0-3、0,1),仅在 NUMA 系统生效。 | ||||||||||||||||
| CpuShares | integer or null <int64> 整数值,表示此容器相对其他容器的 CPU 权重。 | ||||||||||||||||
| DeviceCgroupRules | 数组元素类型 strings or null 要应用到容器的 cgroup 规则列表。 | ||||||||||||||||
数组元素类型 objects or null (ContainerSpecDeviceRequest) 要发送给设备驱动的设备请求列表。 | |||||||||||||||||
Array
| |||||||||||||||||
数组元素类型 objects or null (ContainerSpecDeviceMapping) 要添加到容器的设备列表。 | |||||||||||||||||
Array
| |||||||||||||||||
| Dns | 数组元素类型 strings or null 容器使用的 DNS 服务器列表。 | ||||||||||||||||
| DnsOptions | 数组元素类型 strings or null DNS 选项列表。 | ||||||||||||||||
| DnsSearch | 数组元素类型 strings or null DNS 搜索域列表。 | ||||||||||||||||
| ExtraHosts | 数组元素类型 strings or null 添加到容器 | ||||||||||||||||
| GroupAdd | 数组元素类型 strings or null 容器进程运行时所属的附加用户组列表。 | ||||||||||||||||
| Init | boolean or null 在容器内运行初始化进程,转发信号并回收进程。为空时省略字段,使用守护进程配置的默认值。 | ||||||||||||||||
| IOMaximumBandwidth | integer or null <int64> 容器系统盘的最大每秒 IO 字节数(仅限 Windows)。 | ||||||||||||||||
| IOMaximumIOps | integer or null <int64> 容器系统盘的最大每秒 IO 次数(仅限 Windows)。 | ||||||||||||||||
| IpcMode | string or null 容器 IPC 共享模式,可选值:
| ||||||||||||||||
null or ContainerSpecHostConfigIsolationEnum (string) | |||||||||||||||||
One of null | |||||||||||||||||
| KernelMemoryTCP | integer or null <int64> 内核 TCP 缓冲内存硬限制(字节)。根据 OCI 运行时,此选项可能被忽略。默认 runc 运行时已不再支持。值为空时省略此字段。 | ||||||||||||||||
| Links | 数组元素类型 strings or null 容器链接列表,格式为 | ||||||||||||||||
null or ContainerSpecHostConfigLogConfig (object) | |||||||||||||||||
One of null | |||||||||||||||||
| MaskedPaths | 数组元素类型 strings or null 容器中要屏蔽的路径列表,覆盖默认路径集合。 | ||||||||||||||||
| Memory | integer or null <int64> 内存限制,单位字节。 | ||||||||||||||||
| MemoryReservation | integer or null <int64> 内存软限制,单位字节。 | ||||||||||||||||
| MemorySwap | integer or null <int64> 内存总限制(内存加交换空间)。设为 | ||||||||||||||||
| MemorySwappiness | integer or null <int64> 调整容器内存交换倾向,接受 0 到 100 的整数。 | ||||||||||||||||
数组元素类型 objects or null (ContainerSpecMount) 要添加到容器的挂载规格。 | |||||||||||||||||
Array
| |||||||||||||||||
| NanoCpus | integer or null <int64> CPU 配额,以 10-9 个 CPU 为单位。 | ||||||||||||||||
| NetworkMode | string or null 容器使用的网络模式。支持标准值 | ||||||||||||||||
| OomKillDisable | boolean or null 禁用容器的 OOM killer。 | ||||||||||||||||
| OomScoreAdj | integer or null <int64> 整数值,表示容器的 OOM 分数,用于调整 OOM killer 的选择优先级。 | ||||||||||||||||
| PidMode | string or null 设置容器 PID(进程)命名空间模式,可选值为: | ||||||||||||||||
| PidsLimit | integer or null <int64> 调整容器 PID 限制。 | ||||||||||||||||
null or ContainerSpecHashMap (object) | |||||||||||||||||
One of null | |||||||||||||||||
| Privileged | boolean or null 给予容器对主机的完整访问权限。 | ||||||||||||||||
| PublishAllPorts | boolean or null 为容器所有公开端口分配临时主机端口。容器停止时释放端口,启动时重新分配,因此重启后可能改变。端口从内核决定的临时端口范围选择,例如 Linux 使用 | ||||||||||||||||
| ReadonlyPaths | 数组元素类型 strings or null 容器中要设为只读的路径列表,覆盖默认路径集合。 | ||||||||||||||||
| ReadonlyRootfs | boolean or null 以只读方式挂载容器根文件系统。 | ||||||||||||||||
null or ContainerSpecRestartPolicy (object) | |||||||||||||||||
One of null | |||||||||||||||||
| Runtime | string or null 此容器使用的运行时。 | ||||||||||||||||
| SecurityOpt | 数组元素类型 strings or null 用于自定义 SELinux 等 MLS 系统标签的字符串值列表。 | ||||||||||||||||
| ShmSize | integer or null <int64>
| ||||||||||||||||
object or null 容器存储驱动选项,格式为 | |||||||||||||||||
| |||||||||||||||||
object or null 要在容器中设置的内核参数(sysctl)列表。例如: | |||||||||||||||||
| |||||||||||||||||
object or null 将容器目录映射到 tmpfs 挂载及相应挂载选项。例如: | |||||||||||||||||
| |||||||||||||||||
数组元素类型 objects or null (ContainerSpecResourcesUlimits) 要在容器中设置的资源限制列表。例如: | |||||||||||||||||
Array
| |||||||||||||||||
| UsernsMode | string or null 启用用户命名空间重映射时,设置容器的用户命名空间模式。 | ||||||||||||||||
| UTSMode | string or null 容器使用的 UTS 命名空间。 | ||||||||||||||||
| VolumeDriver | string or null 此容器挂载卷使用的驱动。 | ||||||||||||||||
| VolumesFrom | 数组元素类型 strings or null 从其他容器继承的卷列表,格式为 | ||||||||||||||||
{- "CpuShares": 0,
- "Memory": 0,
- "CgroupParent": "string",
- "BlkioWeight": 0,
- "BlkioWeightDevice": [
- {
- "Path": "string",
- "Weight": 0
}
], - "BlkioDeviceReadBps": [
- {
- "Path": "string",
- "Rate": 0
}
], - "BlkioDeviceWriteBps": [
- {
- "Path": "string",
- "Rate": 0
}
], - "BlkioDeviceReadIOps": [
- {
- "Path": "string",
- "Rate": 0
}
], - "BlkioDeviceWriteIOps": [
- {
- "Path": "string",
- "Rate": 0
}
], - "CpuPeriod": 0,
- "CpuQuota": 0,
- "CpuRealtimePeriod": 0,
- "CpuRealtimeRuntime": 0,
- "CpusetCpus": "string",
- "CpusetMems": "string",
- "Devices": [
- {
- "PathOnHost": "string",
- "PathInContainer": "string",
- "CgroupPermissions": "string"
}
], - "DeviceCgroupRules": [
- "string"
], - "DeviceRequests": [
- {
- "Driver": "string",
- "Count": 0,
- "DeviceIDs": [
- "string"
], - "Capabilities": [
- [
- "string"
]
], - "Options": {
- "property1": "string",
- "property2": "string"
}
}
], - "KernelMemoryTCP": 0,
- "MemoryReservation": 0,
- "MemorySwap": 0,
- "MemorySwappiness": 0,
- "NanoCpus": 0,
- "OomKillDisable": true,
- "Init": true,
- "PidsLimit": 0,
- "Ulimits": [
- {
- "Name": "string",
- "Soft": 0,
- "Hard": 0
}
], - "CpuCount": 0,
- "CpuPercent": 0,
- "IOMaximumIOps": 0,
- "IOMaximumBandwidth": 0,
- "Binds": [
- "string"
], - "ContainerIDFile": "string",
- "LogConfig": { },
- "NetworkMode": "string",
- "PortBindings": { },
- "RestartPolicy": { },
- "AutoRemove": true,
- "VolumeDriver": "string",
- "VolumesFrom": [
- "string"
], - "Mounts": [
- {
- "Target": "string",
- "Source": "string",
- "Type": { },
- "ReadOnly": true,
- "Consistency": "string",
- "BindOptions": { },
- "VolumeOptions": { },
- "TmpfsOptions": { }
}
], - "ConsoleSize": [
- 0
], - "Annotations": {
- "property1": "string",
- "property2": "string"
}, - "CapAdd": [
- "string"
], - "CapDrop": [
- "string"
], - "CgroupnsMode": { },
- "Dns": [
- "string"
], - "DnsOptions": [
- "string"
], - "DnsSearch": [
- "string"
], - "ExtraHosts": [
- "string"
], - "GroupAdd": [
- "string"
], - "IpcMode": "string",
- "Cgroup": "string",
- "Links": [
- "string"
], - "OomScoreAdj": 0,
- "PidMode": "string",
- "Privileged": true,
- "PublishAllPorts": true,
- "ReadonlyRootfs": true,
- "SecurityOpt": [
- "string"
], - "StorageOpt": {
- "property1": "string",
- "property2": "string"
}, - "Tmpfs": {
- "property1": "string",
- "property2": "string"
}, - "UTSMode": "string",
- "UsernsMode": "string",
- "ShmSize": 0,
- "Sysctls": {
- "property1": "string",
- "property2": "string"
}, - "Runtime": "string",
- "Isolation": { },
- "MaskedPaths": [
- "string"
], - "ReadonlyPaths": [
- "string"
]
}"EMPTY""EMPTY"object or null | |||
| |||
| Type | string or null | ||
{- "Type": "string",
- "Config": {
- "property1": "string",
- "property2": "string"
}
}null or ContainerSpecMountBindOptions (object) | |
One of null | |
| Consistency | string or null 挂载一致性要求: |
| ReadOnly | boolean or null 挂载是否应为只读。 |
| Source | string or null 挂载源,例如卷名称或主机路径。 |
| Target | string or null 容器路径。 |
null or ContainerSpecMountTmpfsOptions (object) | |
One of null | |
null or ContainerSpecMountTypeEnum (string) | |
One of null | |
null or ContainerSpecMountVolumeOptions (object) | |
One of null | |
{- "Target": "string",
- "Source": "string",
- "Type": { },
- "ReadOnly": true,
- "Consistency": "string",
- "BindOptions": { },
- "VolumeOptions": { },
- "TmpfsOptions": { }
}| CreateMountpoint | boolean or null 主机挂载点缺失时创建。 |
| NonRecursive | boolean or null 禁用递归绑定挂载。 |
null or ContainerSpecMountBindOptionsPropagationEnum (string) | |
One of null | |
| ReadOnlyForceRecursive | boolean or null 无法将挂载设为递归只读时返回错误。 |
| ReadOnlyNonRecursive | boolean or null 让挂载自身只读而非递归只读,但仍保留递归挂载(除非同时将 NonRecursive 设为 |
{- "Propagation": { },
- "NonRecursive": true,
- "CreateMountpoint": true,
- "ReadOnlyNonRecursive": true,
- "ReadOnlyForceRecursive": true
}"EMPTY"| Mode | integer or null <int64> tmpfs 挂载的权限模式,以整数表示。 |
| SizeBytes | integer or null <int64> tmpfs 挂载大小,单位字节。 |
{- "SizeBytes": 0,
- "Mode": 0
}"EMPTY"null or ContainerSpecMountVolumeOptionsDriverConfig (object) | |||
One of null | |||
object or null 用户定义的键值元数据。 | |||
| |||
| NoCopy | boolean or null 使用目标数据填充卷。 | ||
| Subpath | string or null 卷内的源路径,必须是相对路径,且不能包含向父目录回退的片段。 | ||
{- "NoCopy": true,
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "DriverConfig": { },
- "Subpath": "string"
}| Name | string or null 创建卷所用驱动名称。 | ||
object or null 驱动专属选项的键值映射。 | |||
| |||
{- "Name": "string",
- "Options": {
- "property1": "string",
- "property2": "string"
}
}required | object | ||
| |||
{- "EndpointsConfig": {
- "property1": {
- "IPAMConfig": { },
- "Links": [
- "string"
], - "MacAddress": "string",
- "Aliases": [
- "string"
], - "NetworkID": "string",
- "EndpointID": "string",
- "Gateway": "string",
- "IPAddress": "string",
- "IPPrefixLen": 0,
- "IPv6Gateway": "string",
- "GlobalIPv6Address": "string",
- "GlobalIPv6PrefixLen": 0,
- "DriverOpts": {
- "property1": "string",
- "property2": "string"
}, - "DNSNames": [
- "string"
]
}, - "property2": {
- "IPAMConfig": { },
- "Links": [
- "string"
], - "MacAddress": "string",
- "Aliases": [
- "string"
], - "NetworkID": "string",
- "EndpointID": "string",
- "Gateway": "string",
- "IPAddress": "string",
- "IPPrefixLen": 0,
- "IPv6Gateway": "string",
- "GlobalIPv6Address": "string",
- "GlobalIPv6PrefixLen": 0,
- "DriverOpts": {
- "property1": "string",
- "property2": "string"
}, - "DNSNames": [
- "string"
]
}
}
}| Path | string or null |
| Weight | integer or null >= 0 |
{- "Path": "string",
- "Weight": 0
}| Hard | integer or null <int64> 硬限制。 |
| Name | string or null ulimit 名称。 |
| Soft | integer or null <int64> 软限制。 |
{- "Name": "string",
- "Soft": 0,
- "Hard": 0
}| MaximumRetryCount | integer or null <int64> 使用 |
null or ContainerSpecRestartPolicyNameEnum (string) | |
One of null | |
{- "Name": { },
- "MaximumRetryCount": 0
}"EMPTY"| Path | string or null 设备路径。 |
| Rate | integer or null <int64> 速率。 |
{- "Path": "string",
- "Rate": 0
}| Dead | boolean or null |
| Error | string or null |
| ExitCode | integer or null <int64> 容器最近退出码。 |
| FinishedAt | string or null 容器最近退出时间。 |
null or Health (object) | |
One of null | |
| OOMKilled | boolean or null 容器最近启动以来,内部进程是否因内存不足被终止。 |
| Paused | boolean or null 容器是否暂停。 |
| Pid | integer or null <int64> 容器进程 ID。 |
| Restarting | boolean or null 容器是否正在重启。 |
| Running | boolean or null 容器是否运行。注意运行容器也可_暂停_, |
| StartedAt | string or null 容器最近启动时间。 |
null or ContainerStateStatusEnum (string) | |
One of null | |
{- "Status": { },
- "Running": true,
- "Paused": true,
- "Restarting": true,
- "OOMKilled": true,
- "Dead": true,
- "Pid": 0,
- "ExitCode": 0,
- "Error": "string",
- "StartedAt": "string",
- "FinishedAt": "string",
- "Health": { }
}"EMPTY"| advertise_addr required | string 向其他节点公布的地址。 |
| conf_dir required | string 配置目录。 |
| docker_host | string 使用的 Docker 主机。 |
| gateway required | string 主机网关,未设置时自动检测默认网关。 |
| gid required | integer <int32> >= 0 用户组 ID。 |
| hostname required | string 节点使用的主机名,未设置时自动检测。 |
| hosts required | 数组元素类型 strings 监听地址列表。 |
| nodes required | 数组元素类型 strings 要加入的节点列表。 |
null or SslConfig (object) | |
One of null | |
| state_dir required | string 状态目录路径。 |
| store_addr | string or null 存储连接地址。 |
{- "hosts": [
- "string"
], - "state_dir": "string",
- "docker_host": "string",
- "store_addr": "string",
- "gateway": "string",
- "hostname": "string",
- "nodes": [
- "string"
], - "advertise_addr": "string",
- "conf_dir": "string",
- "gid": 0,
- "ssl": { }
}| CgroupPermissions | string or null |
| PathInContainer | string or null |
| PathOnHost | string or null |
{- "PathOnHost": "string",
- "PathInContainer": "string",
- "CgroupPermissions": "string"
}| Capabilities | 数组元素类型 strings or null[ items ] 权限能力列表,由多个“与”能力列表以“或”关系组成。 | ||
| Count | integer or null <int64> | ||
| DeviceIDs | 数组元素类型 strings or null | ||
| Driver | string or null | ||
object or null 驱动专属选项,以键值对指定,直接传递给驱动。 | |||
| |||
{- "Driver": "string",
- "Count": 0,
- "DeviceIDs": [
- "string"
], - "Capabilities": [
- [
- "string"
]
], - "Options": {
- "property1": "string",
- "property2": "string"
}
}required | string or object or object (NetworkKind) |
One of string 网络绑定选择器。 | |
| Name required | string |
{- "Name": "string",
- "IpAddress": "string"
}| IPv4Address | string or null |
| IPv6Address | string or null |
| LinkLocalIPs | 数组元素类型 strings or null |
{- "IPv4Address": "string",
- "IPv6Address": "string",
- "LinkLocalIPs": [
- "string"
]
}| Aliases | 数组元素类型 strings or null | ||
| DNSNames | 数组元素类型 strings or null 端点在指定网络上的全部 DNS 名称,来自容器名称、网络别名、容器短 ID 和主机名。名称不是完全限定名称,但可包含多个点。添加 | ||
object or null DriverOpts 是驱动选项和值的映射,直接传递给驱动,内容由具体驱动决定。 | |||
| |||
| EndpointID | string or null 沙箱中服务端点的唯一 ID。 | ||
| Gateway | string or null 此网络的网关地址。 | ||
| GlobalIPv6Address | string or null 全局 IPv6 地址。 | ||
| GlobalIPv6PrefixLen | integer or null <int64> 全局 IPv6 地址掩码长度。 | ||
| IPAddress | string or null IPv4 地址。 | ||
null or EndpointIpamConfig (object) | |||
One of null | |||
| IPPrefixLen | integer or null <int64> IPv4 地址掩码长度。 | ||
| IPv6Gateway | string or null IPv6 网关地址。 | ||
| Links | 数组元素类型 strings or null | ||
| MacAddress | string or null 端点在此网络上的 MAC 地址,网络驱动可能忽略此参数。 | ||
| NetworkID | string or null 网络唯一 ID。 | ||
{- "IPAMConfig": { },
- "Links": [
- "string"
], - "MacAddress": "string",
- "Aliases": [
- "string"
], - "NetworkID": "string",
- "EndpointID": "string",
- "Gateway": "string",
- "IPAddress": "string",
- "IPPrefixLen": 0,
- "IPv6Gateway": "string",
- "GlobalIPv6Address": "string",
- "GlobalIPv6PrefixLen": 0,
- "DriverOpts": {
- "property1": "string",
- "property2": "string"
}, - "DNSNames": [
- "string"
]
}| Action required | string Action 表示针对相关对象执行或失败的操作,供机器读取。新事件的此字段不能为空,最多 128 个字符。 | ||
null or EventActor (object) | |||
One of null | |||
| CreatedAt required | string <date-time> 事件创建时间。 | ||
| ExpiresAt required | string <date-time> 事件到期时间。 | ||
| Key required | string <uuid> 事件唯一标识。 | ||
| Kind required | string (EventKind) 枚举值: "error" "normal" "warning" 此事件的类型(Error、Normal、Warning),未来可能新增类型。供机器读取;新事件的此字段不能为空。 | ||
object 标准元数据。 | |||
| |||
| Note | string or null 此次操作状态的人类可读描述。 | ||
| Reason required | string Reason 是执行操作的原因,供人阅读。新事件的此字段不能为空,最多 128 个字符。 | ||
null or EventActor (object) | |||
One of null | |||
| ReportingController required | string Reporting Controller 是发出此事件的控制器名称,如 | ||
| ReportingNode required | string Reporting Node 是生成事件的节点名称。 | ||
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ExpiresAt": "2019-08-24T14:15:22Z",
- "ReportingNode": "string",
- "ReportingController": "string",
- "Kind": "error",
- "Action": "string",
- "Reason": "string",
- "Note": "string",
- "Actor": { },
- "Related": { },
- "Metadata": {
- "property1": "string",
- "property2": "string"
}
}object | |||
| |||
| Key | string or null | ||
| Kind required | string (EventActorKind) 枚举值: "Namespace" "Cargo" "Vm" "Job" "Resource" "Secret" "Process" "ContainerImage" Kind 是与对象类型相关的事件类型。 | ||
{- "Key": "string",
- "Kind": "Namespace",
- "Attributes": {
- "property1": "string",
- "property2": "string"
}
}Kind 是与对象类型相关的事件类型。
"Namespace"required | 数组元素类型 strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or strings or objects (NativeEventAction) |
Array One of string 值: "create" Action 是触发事件的操作。 | |
| ActorKey | string or null |
null or EventActorKind (string) | |
One of null | |
| Kind required | 数组元素类型 strings (EventKind) 允许的元素 枚举值: "error" "normal" "warning" |
| RelatedKey | string or null |
null or EventActorKind (string) | |
One of null | |
{- "ActorKey": "string",
- "ActorKind": { },
- "RelatedKey": "string",
- "RelatedKind": { },
- "Kind": [
- "error"
], - "Action": [
- "create"
]
}事件类型(Error、Normal、Warning),未来可能新增类型。
"error"null or GenericResourcesInnerDiscreteResourceSpec (object) | |
One of null | |
null or GenericResourcesInnerNamedResourceSpec (object) | |
One of null | |
{- "NamedResourceSpec": { },
- "DiscreteResourceSpec": { }
}| Kind | string or null |
| Value | integer or null <int64> |
{- "Kind": "string",
- "Value": 0
}| Kind | string or null |
| Value | string or null |
{- "Kind": "string",
- "Value": "string"
}required | object 底层存储元数据,以键值对提供。信息由所用存储驱动决定,仅供参考。 | ||
| |||
| Name required | string 存储驱动名称。 | ||
{- "Name": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}
}| FailingStreak | integer or null <int64> FailingStreak 是连续失败次数。 | ||||||||
数组元素类型 objects or null (HealthcheckResult) Log 包含最近几次结果,最旧的在前。 | |||||||||
Array
| |||||||||
null or HealthStatusEnum (string) | |||||||||
One of null | |||||||||
{- "Status": { },
- "FailingStreak": 0,
- "Log": [
- {
- "Start": { },
- "End": { },
- "ExitCode": 0,
- "Output": "string"
}
]
}| Interval | integer or null <int64> 检查之间的等待时间,单位纳秒。应为 0 或至少 1000000(1 毫秒),0 表示继承。 |
| Retries | integer or null <int64> 将容器视为不健康所需的连续失败次数,0 表示继承。 |
| StartInterval | integer or null <int64> 启动宽限期内检查之间的等待时间,单位纳秒。应为 0 或至少 1000000(1 毫秒),0 表示继承。 |
| StartPeriod | integer or null <int64> 容器初始化的启动宽限期,在此期间不开始健康检查重试倒计时,单位纳秒。应为 0 或至少 1000000(1 毫秒),0 表示继承。 |
| Test | 数组元素类型 strings or null 要执行的测试,可选值: |
| Timeout | integer or null <int64> 判定检查卡住之前的等待时间,应为 0 或至少 1000000(1 毫秒),0 表示继承。 |
{- "Test": [
- "string"
], - "Interval": 0,
- "Timeout": 0,
- "Retries": 0,
- "StartPeriod": 0,
- "StartInterval": 0
}"EMPTY"null or String (string) | |
One of null | |
| ExitCode | integer or null <int64> ExitCode 的含义: |
| Output | string or null 最近一次检查的输出。 |
null or String (string) | |
One of null | |
{- "Start": { },
- "End": { },
- "ExitCode": 0,
- "Output": "string"
}object or null 附加到容器的任意非标识元数据,在容器启动时提供给运行时。 | |||||||||||||||||
| |||||||||||||||||
| AutoRemove | boolean or null 容器进程退出时自动移除容器。设置 | ||||||||||||||||
| Binds | 数组元素类型 strings or null 容器的卷绑定列表,每项是以下格式之一的字符串:
| ||||||||||||||||
数组元素类型 objects or null (ThrottleDevice) 限制设备读取速率(每秒字节数),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
数组元素类型 objects or null (ThrottleDevice) 限制设备读取速率(每秒 IO 次数),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
数组元素类型 objects or null (ThrottleDevice) 限制设备写入速率(每秒字节数),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
数组元素类型 objects or null (ThrottleDevice) 限制设备写入速率(每秒 IO 次数),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
| BlkioWeight | integer or null <int32> >= 0 块 IO 权重(相对权重)。 | ||||||||||||||||
数组元素类型 objects or null (ResourcesBlkioWeightDevice) 块 IO 权重(相对设备权重),格式为: | |||||||||||||||||
Array
| |||||||||||||||||
| CapAdd | 数组元素类型 strings or null 要添加到容器的内核权限能力列表,与 'Capabilities' 选项冲突。 | ||||||||||||||||
| CapDrop | 数组元素类型 strings or null 要从容器移除的内核权限能力列表,与 'Capabilities' 选项冲突。 | ||||||||||||||||
| Cgroup | string or null 容器使用的 cgroup。 | ||||||||||||||||
null or HostConfigCgroupnsModeEnum (string) | |||||||||||||||||
One of null | |||||||||||||||||
| CgroupParent | string or null
| ||||||||||||||||
| ConsoleSize | 数组元素类型 integers or null <int32> [ items <int32 > ] 初始控制台大小,以 | ||||||||||||||||
| ContainerIDFile | string or null 写入容器 ID 的文件路径。 | ||||||||||||||||
| CpuCount | integer or null <int64> 可用 CPU 数量,仅限 Windows。Windows Server 容器的处理器资源控制互斥,优先级依次为 | ||||||||||||||||
| CpuPercent | integer or null <int64> 可用 CPU 的使用比例,仅限 Windows。Windows Server 容器的处理器资源控制互斥,优先级依次为 | ||||||||||||||||
| CpuPeriod | integer or null <int64> CPU 周期长度,单位微秒。 | ||||||||||||||||
| CpuQuota | integer or null <int64> 容器在一个 CPU 周期内可获得的 CPU 时间,单位微秒。 | ||||||||||||||||
| CpuRealtimePeriod | integer or null <int64> CPU 实时周期长度,单位微秒。设为 0 时不给实时任务分配时间。 | ||||||||||||||||
| CpuRealtimeRuntime | integer or null <int64> CPU 实时运行时间长度,单位微秒。设为 0 时不给实时任务分配时间。 | ||||||||||||||||
| CpusetCpus | string or null 允许执行的 CPU(如 | ||||||||||||||||
| CpusetMems | string or null 允许执行的内存节点 MEM(0-3、0,1),仅在 NUMA 系统生效。 | ||||||||||||||||
| CpuShares | integer or null <int64> 整数值,表示此容器相对其他容器的 CPU 权重。 | ||||||||||||||||
| DeviceCgroupRules | 数组元素类型 strings or null 要应用到容器的 cgroup 规则列表。 | ||||||||||||||||
数组元素类型 objects or null (DeviceRequest) 要发送给设备驱动的设备请求列表。 | |||||||||||||||||
Array
| |||||||||||||||||
数组元素类型 objects or null (DeviceMapping) 要添加到容器的设备列表。 | |||||||||||||||||
Array
| |||||||||||||||||
| Dns | 数组元素类型 strings or null 容器使用的 DNS 服务器列表。 | ||||||||||||||||
| DnsOptions | 数组元素类型 strings or null DNS 选项列表。 | ||||||||||||||||
| DnsSearch | 数组元素类型 strings or null DNS 搜索域列表。 | ||||||||||||||||
| ExtraHosts | 数组元素类型 strings or null 添加到容器 | ||||||||||||||||
| GroupAdd | 数组元素类型 strings or null 容器进程运行时所属的附加用户组列表。 | ||||||||||||||||
| Init | boolean or null 在容器内运行初始化进程,转发信号并回收进程。为空时省略字段,使用守护进程配置的默认值。 | ||||||||||||||||
| IOMaximumBandwidth | integer or null <int64> 容器系统盘的最大每秒 IO 字节数(仅限 Windows)。 | ||||||||||||||||
| IOMaximumIOps | integer or null <int64> 容器系统盘的最大每秒 IO 次数(仅限 Windows)。 | ||||||||||||||||
| IpcMode | string or null 容器 IPC 共享模式,可选值:
| ||||||||||||||||
null or HostConfigIsolationEnum (string) | |||||||||||||||||
One of null | |||||||||||||||||
| KernelMemoryTCP | integer or null <int64> 内核 TCP 缓冲内存硬限制(字节)。根据 OCI 运行时,此选项可能被忽略。默认 runc 运行时已不再支持。值为空时省略此字段。 | ||||||||||||||||
| Links | 数组元素类型 strings or null 容器链接列表,格式为 | ||||||||||||||||
null or HostConfigLogConfig (object) | |||||||||||||||||
One of null | |||||||||||||||||
| MaskedPaths | 数组元素类型 strings or null 容器中要屏蔽的路径列表,覆盖默认路径集合。 | ||||||||||||||||
| Memory | integer or null <int64> 内存限制,单位字节。 | ||||||||||||||||
| MemoryReservation | integer or null <int64> 内存软限制,单位字节。 | ||||||||||||||||
| MemorySwap | integer or null <int64> 内存总限制(内存加交换空间)。设为 | ||||||||||||||||
| MemorySwappiness | integer or null <int64> 调整容器内存交换倾向,接受 0 到 100 的整数。 | ||||||||||||||||
数组元素类型 objects or null (Mount) 要添加到容器的挂载规格。 | |||||||||||||||||
Array
| |||||||||||||||||
| NanoCpus | integer or null <int64> CPU 配额,以 10-9 个 CPU 为单位。 | ||||||||||||||||
| NetworkMode | string or null 容器使用的网络模式。支持标准值 | ||||||||||||||||
| OomKillDisable | boolean or null 禁用容器的 OOM killer。 | ||||||||||||||||
| OomScoreAdj | integer or null <int64> 整数值,表示容器的 OOM 分数,用于调整 OOM killer 的选择优先级。 | ||||||||||||||||
| PidMode | string or null 设置容器 PID(进程)命名空间模式,可选值为: | ||||||||||||||||
| PidsLimit | integer or null <int64> 调整容器 PID 限制。 | ||||||||||||||||
null or HashMap (object) | |||||||||||||||||
One of null | |||||||||||||||||
| Privileged | boolean or null 给予容器对主机的完整访问权限。 | ||||||||||||||||
| PublishAllPorts | boolean or null 为容器所有公开端口分配临时主机端口。容器停止时释放端口,启动时重新分配,因此重启后可能改变。端口从内核决定的临时端口范围选择,例如 Linux 使用 | ||||||||||||||||
| ReadonlyPaths | 数组元素类型 strings or null 容器中要设为只读的路径列表,覆盖默认路径集合。 | ||||||||||||||||
| ReadonlyRootfs | boolean or null 以只读方式挂载容器根文件系统。 | ||||||||||||||||
null or RestartPolicy (object) | |||||||||||||||||
One of null | |||||||||||||||||
| Runtime | string or null 此容器使用的运行时。 | ||||||||||||||||
| SecurityOpt | 数组元素类型 strings or null 用于自定义 SELinux 等 MLS 系统标签的字符串值列表。 | ||||||||||||||||
| ShmSize | integer or null <int64>
| ||||||||||||||||
object or null 容器存储驱动选项,格式为 | |||||||||||||||||
| |||||||||||||||||
object or null 要在容器中设置的内核参数(sysctl)列表。例如: | |||||||||||||||||
| |||||||||||||||||
object or null 将容器目录映射到 tmpfs 挂载及相应挂载选项。例如: | |||||||||||||||||
| |||||||||||||||||
数组元素类型 objects or null (ResourcesUlimits) 要在容器中设置的资源限制列表。例如: | |||||||||||||||||
Array
| |||||||||||||||||
| UsernsMode | string or null 启用用户命名空间重映射时,设置容器的用户命名空间模式。 | ||||||||||||||||
| UTSMode | string or null 容器使用的 UTS 命名空间。 | ||||||||||||||||
| VolumeDriver | string or null 此容器挂载卷使用的驱动。 | ||||||||||||||||
| VolumesFrom | 数组元素类型 strings or null 从其他容器继承的卷列表,格式为 | ||||||||||||||||
{- "CpuShares": 0,
- "Memory": 0,
- "CgroupParent": "string",
- "BlkioWeight": 0,
- "BlkioWeightDevice": [
- {
- "Path": "string",
- "Weight": 0
}
], - "BlkioDeviceReadBps": [
- {
- "Path": "string",
- "Rate": 0
}
], - "BlkioDeviceWriteBps": [
- {
- "Path": "string",
- "Rate": 0
}
], - "BlkioDeviceReadIOps": [
- {
- "Path": "string",
- "Rate": 0
}
], - "BlkioDeviceWriteIOps": [
- {
- "Path": "string",
- "Rate": 0
}
], - "CpuPeriod": 0,
- "CpuQuota": 0,
- "CpuRealtimePeriod": 0,
- "CpuRealtimeRuntime": 0,
- "CpusetCpus": "string",
- "CpusetMems": "string",
- "Devices": [
- {
- "PathOnHost": "string",
- "PathInContainer": "string",
- "CgroupPermissions": "string"
}
], - "DeviceCgroupRules": [
- "string"
], - "DeviceRequests": [
- {
- "Driver": "string",
- "Count": 0,
- "DeviceIDs": [
- "string"
], - "Capabilities": [
- [
- "string"
]
], - "Options": {
- "property1": "string",
- "property2": "string"
}
}
], - "KernelMemoryTCP": 0,
- "MemoryReservation": 0,
- "MemorySwap": 0,
- "MemorySwappiness": 0,
- "NanoCpus": 0,
- "OomKillDisable": true,
- "Init": true,
- "PidsLimit": 0,
- "Ulimits": [
- {
- "Name": "string",
- "Soft": 0,
- "Hard": 0
}
], - "CpuCount": 0,
- "CpuPercent": 0,
- "IOMaximumIOps": 0,
- "IOMaximumBandwidth": 0,
- "Binds": [
- "string"
], - "ContainerIDFile": "string",
- "LogConfig": { },
- "NetworkMode": "string",
- "PortBindings": { },
- "RestartPolicy": { },
- "AutoRemove": true,
- "VolumeDriver": "string",
- "VolumesFrom": [
- "string"
], - "Mounts": [
- {
- "Target": "string",
- "Source": "string",
- "Type": { },
- "ReadOnly": true,
- "Consistency": "string",
- "BindOptions": { },
- "VolumeOptions": { },
- "TmpfsOptions": { }
}
], - "ConsoleSize": [
- 0
], - "Annotations": {
- "property1": "string",
- "property2": "string"
}, - "CapAdd": [
- "string"
], - "CapDrop": [
- "string"
], - "CgroupnsMode": { },
- "Dns": [
- "string"
], - "DnsOptions": [
- "string"
], - "DnsSearch": [
- "string"
], - "ExtraHosts": [
- "string"
], - "GroupAdd": [
- "string"
], - "IpcMode": "string",
- "Cgroup": "string",
- "Links": [
- "string"
], - "OomScoreAdj": 0,
- "PidMode": "string",
- "Privileged": true,
- "PublishAllPorts": true,
- "ReadonlyRootfs": true,
- "SecurityOpt": [
- "string"
], - "StorageOpt": {
- "property1": "string",
- "property2": "string"
}, - "Tmpfs": {
- "property1": "string",
- "property2": "string"
}, - "UTSMode": "string",
- "UsernsMode": "string",
- "ShmSize": 0,
- "Sysctls": {
- "property1": "string",
- "property2": "string"
}, - "Runtime": "string",
- "Isolation": { },
- "MaskedPaths": [
- "string"
], - "ReadonlyPaths": [
- "string"
]
}"EMPTY"object or null | |||
| |||
| Type | string or null | ||
{- "Type": "string",
- "Config": {
- "property1": "string",
- "property2": "string"
}
}| Architecture | string or null 主机硬件架构,由 Go 运行时( | ||||||||||||||||||||||||||
| BridgeNfIp6tables | boolean or null 表示主机是否提供 | ||||||||||||||||||||||||||
| BridgeNfIptables | boolean or null 表示主机是否提供 | ||||||||||||||||||||||||||
| CDISpecDirs | 数组元素类型 strings or null CDI(Container Device Interface)规范所在目录列表。规范定义创建容器时,对 OCI 运行时规格所做的厂商专属修改。列表为空表示禁用 CDI 设备注入。CDI 注入要求守护进程启用实验性功能,非实验性守护进程始终返回空列表。 | ||||||||||||||||||||||||||
null or SystemInfoCgroupDriverEnum (string) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
null or SystemInfoCgroupVersionEnum (string) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
required | object (DaemonConfig) 守护进程配置。 | ||||||||||||||||||||||||||
| |||||||||||||||||||||||||||
null or Commit (object) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
| Containers | integer or null <int64> 主机容器总数。 | ||||||||||||||||||||||||||
| ContainersPaused | integer or null <int64> 状态为 | ||||||||||||||||||||||||||
| ContainersRunning | integer or null <int64> 状态为 | ||||||||||||||||||||||||||
| ContainersStopped | integer or null <int64> 状态为 | ||||||||||||||||||||||||||
| CpuCfsPeriod | boolean or null 表示主机是否支持 CPU CFS(完全公平调度器)周期。 | ||||||||||||||||||||||||||
| CpuCfsQuota | boolean or null 表示主机是否支持 CPU CFS(完全公平调度器)配额。 | ||||||||||||||||||||||||||
| CPUSet | boolean or null 表示主机是否支持 CPUset(cpuset.cpus、cpuset.mems)。参见 cpuset(7)。 | ||||||||||||||||||||||||||
| CPUShares | boolean or null 表示主机是否支持 CPU Shares 限制。 | ||||||||||||||||||||||||||
| Debug | boolean or null 表示守护进程是否在调试模式运行,或启用了调试级日志。 | ||||||||||||||||||||||||||
数组元素类型 objects or null (SystemInfoDefaultAddressPools) 本地网络的自定义默认地址池列表,可在 daemon.json 或 dockerd 选项中指定。例如 Base 为 "10.10.0.0/16"、Size 为 24 时,会定义 256 个 10.10.[0-255].0/24 地址池。 | |||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||
| DefaultRuntime | string or null 启动容器时默认使用的 OCI 运行时名称,可在创建各容器时覆盖。 | ||||||||||||||||||||||||||
| DockerRootDir | string or null Docker 持久化状态根目录。Linux 默认为 | ||||||||||||||||||||||||||
| Driver | string or null 正在使用的存储驱动名称。 | ||||||||||||||||||||||||||
| DriverStatus | 数组元素类型 strings or null[ items ] 存储驱动专属信息,由驱动提供 "label" / "value" 对,格式与命令行 | ||||||||||||||||||||||||||
| ExperimentalBuild | boolean or null 表示守护进程是否启用实验性功能。 | ||||||||||||||||||||||||||
null or GenericResourcesInner (object) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
| HostGateway required | string HostGateway 是主机网关地址。 | ||||||||||||||||||||||||||
| HttpProxy | string or null 守护进程的 HTTP 代理配置,来自 | ||||||||||||||||||||||||||
| HttpsProxy | string or null 守护进程的 HTTPS 代理配置,来自 | ||||||||||||||||||||||||||
| ID | string or null 守护进程唯一标识。 | ||||||||||||||||||||||||||
| Images | integer or null <int64> 主机镜像总数,包括_有标签_和_无标签_(悬空)镜像。 | ||||||||||||||||||||||||||
| IndexServerAddress | string or null 镜像搜索所用索引服务器的地址或 URL,也作为 Docker Hub 和 Docker Cloud 用户认证的默认服务器。 | ||||||||||||||||||||||||||
| InitBinary | string or null
| ||||||||||||||||||||||||||
null or Commit (object) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
| IPv4Forwarding | boolean or null 表示是否启用 IPv4 转发。 | ||||||||||||||||||||||||||
null or SystemInfoIsolationEnum (string) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
| KernelMemoryTCP | boolean or null 表示主机是否启用内核 TCP 内存限制,不支持时省略。cgroup v2 不支持内核 TCP 内存限制及对应的 | ||||||||||||||||||||||||||
| KernelVersion | string or null 主机内核版本。Linux 从 | ||||||||||||||||||||||||||
| Labels | 数组元素类型 strings or null 守护进程上设置的用户自定义标签(键值元数据)。 /nodes/(id) 端点获取。
| ||||||||||||||||||||||||||
| LiveRestoreEnabled | boolean or null 表示是否启用 live restore。启用后,守护进程关闭时容器继续运行;守护进程启动并检测到运行中的容器时也保持运行。 | ||||||||||||||||||||||||||
| LoggingDriver | string or null 新容器默认使用的日志驱动。 | ||||||||||||||||||||||||||
| MemoryLimit | boolean or null 表示主机是否支持内存限制。 | ||||||||||||||||||||||||||
| MemTotal | integer or null <int64> 主机可用物理内存总量,单位字节。 | ||||||||||||||||||||||||||
| Name | string or null 主机的主机名。 | ||||||||||||||||||||||||||
| NCPU | integer or null <int64> 守护进程可使用的逻辑 CPU 数量,启动时通过操作系统查询。启动后操作系统 CPU 分配变化不会反映在此值中。 | ||||||||||||||||||||||||||
required | object (Network) 网络配置。 | ||||||||||||||||||||||||||
| |||||||||||||||||||||||||||
| NEventsListener | integer or null <int64> 已订阅的事件监听器数量。 | ||||||||||||||||||||||||||
| NFd | integer or null <int64> 守护进程使用的文件描述符总数,仅在启用调试模式时返回。 | ||||||||||||||||||||||||||
| NGoroutines | integer or null <int64> 当前 goroutine 数量,仅在启用调试模式时返回。 | ||||||||||||||||||||||||||
| NoProxy | string or null 不使用代理的域名后缀列表,以逗号分隔。此值来自 | ||||||||||||||||||||||||||
| OomKillDisable | boolean or null 表示主机是否支持禁用 OOM killer。 | ||||||||||||||||||||||||||
| OperatingSystem | string or null 主机操作系统名称,如 "Ubuntu 16.04.2 LTS" 或 "Windows Server 2016 Datacenter"。 | ||||||||||||||||||||||||||
| OSType | string or null 主机操作系统的通用类型,由 Go 运行时( | ||||||||||||||||||||||||||
| OSVersion | string or null 主机操作系统版本。 | ||||||||||||||||||||||||||
| PidsLimit | boolean or null 表示主机内核是否支持 PID 限制。 | ||||||||||||||||||||||||||
null or PluginsInfo (object) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
| ProductLicense | string or null 报告守护进程的产品许可证摘要。如果应用了商业许可证,会包含节点数量和到期时间等信息。 | ||||||||||||||||||||||||||
null or RegistryServiceConfig (object) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
null or Commit (object) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
object or null 守护进程配置的 OCI 兼容运行时列表,键保存引用运行时的名称。Docker 守护进程依靠经 | |||||||||||||||||||||||||||
| |||||||||||||||||||||||||||
| SecurityOptions | 数组元素类型 strings or null 守护进程启用的安全功能列表,如 apparmor、seccomp、SELinux、用户命名空间 userns、rootless 和 no-new-privileges。各功能可能包含额外配置,以逗号分隔的键值对列出。 | ||||||||||||||||||||||||||
| ServerVersion | string or null 守护进程版本字符串。 | ||||||||||||||||||||||||||
| SwapLimit | boolean or null 表示主机是否支持交换内存限制。 | ||||||||||||||||||||||||||
null or SwarmInfo (object) | |||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||
| SystemTime | string or null 当前系统时间,使用纳秒精度的 RFC 3339 格式。 | ||||||||||||||||||||||||||
| Warnings | 数组元素类型 strings or null 缺失功能或守护进程配置问题的警告和信息消息列表,客户端可将这些消息展示给用户。 | ||||||||||||||||||||||||||
{- "ID": "string",
- "Containers": 0,
- "ContainersRunning": 0,
- "ContainersPaused": 0,
- "ContainersStopped": 0,
- "Images": 0,
- "Driver": "string",
- "DriverStatus": [
- [
- "string"
]
], - "DockerRootDir": "string",
- "Plugins": { },
- "MemoryLimit": true,
- "SwapLimit": true,
- "KernelMemoryTCP": true,
- "CpuCfsPeriod": true,
- "CpuCfsQuota": true,
- "CPUShares": true,
- "CPUSet": true,
- "PidsLimit": true,
- "OomKillDisable": true,
- "IPv4Forwarding": true,
- "BridgeNfIptables": true,
- "BridgeNfIp6tables": true,
- "Debug": true,
- "NFd": 0,
- "NGoroutines": 0,
- "SystemTime": "string",
- "LoggingDriver": "string",
- "CgroupDriver": { },
- "CgroupVersion": { },
- "NEventsListener": 0,
- "KernelVersion": "string",
- "OperatingSystem": "string",
- "OSVersion": "string",
- "OSType": "string",
- "Architecture": "string",
- "NCPU": 0,
- "MemTotal": 0,
- "IndexServerAddress": "string",
- "RegistryConfig": { },
- "GenericResources": { },
- "HttpProxy": "string",
- "HttpsProxy": "string",
- "NoProxy": "string",
- "Name": "string",
- "Labels": [
- "string"
], - "ExperimentalBuild": true,
- "ServerVersion": "string",
- "Runtimes": {
- "property1": {
- "path": "string",
- "runtimeArgs": [
- "string"
], - "status": {
- "property1": "string",
- "property2": "string"
}
}, - "property2": {
- "path": "string",
- "runtimeArgs": [
- "string"
], - "status": {
- "property1": "string",
- "property2": "string"
}
}
}, - "DefaultRuntime": "string",
- "Swarm": { },
- "LiveRestoreEnabled": true,
- "Isolation": { },
- "InitBinary": "string",
- "ContainerdCommit": { },
- "RuncCommit": { },
- "InitCommit": { },
- "SecurityOptions": [
- "string"
], - "ProductLicense": "string",
- "DefaultAddressPools": [
- {
- "Base": "string",
- "Size": 0
}
], - "Warnings": [
- "string"
], - "CDISpecDirs": [
- "string"
], - "HostGateway": "string",
- "Network": {
- "Name": "string",
- "Id": "string",
- "Created": { },
- "Scope": "string",
- "Driver": "string",
- "EnableIPv6": true,
- "IPAM": { },
- "Internal": true,
- "Attachable": true,
- "Ingress": true,
- "Containers": {
- "property1": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}, - "property2": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}
}, - "Options": {
- "property1": "string",
- "property2": "string"
}, - "Labels": {
- "property1": "string",
- "property2": "string"
}
}, - "Config": {
- "hosts": [
- "string"
], - "state_dir": "string",
- "docker_host": "string",
- "store_addr": "string",
- "gateway": "string",
- "hostname": "string",
- "nodes": [
- "string"
], - "advertise_addr": "string",
- "conf_dir": "string",
- "gid": 0,
- "ssl": { }
}
}{- "Config": {
- "MaxAge": 0,
- "Preload": true,
- "Always": true,
- "IncludeSubDomains": true
}
}| Always required | boolean |
| IncludeSubDomains required | boolean |
| MaxAge required | integer <int64> >= 0 |
| Preload required | boolean |
{- "MaxAge": 0,
- "Preload": true,
- "Always": true,
- "IncludeSubDomains": true
}null or UrlRedirect (string) | |
One of null | |
| Url required | string 目标 URL。 |
{- "Url": "string",
- "Redirect": { }
}进程对象(Job、Cargo、VM)相关镜像的拉取策略。
"Never"| Mirrors | 数组元素类型 strings or null 镜像源列表,以 URI 表示。 |
| Name | string or null 镜像仓库名称,如 "docker.io"。 |
| Official | boolean or null 表示是否为官方镜像仓库(Docker Hub / docker.io)。 |
| Secure | boolean or null 表示镜像仓库是否属于不安全仓库列表。值为 |
{- "Name": "string",
- "Mirrors": [
- "string"
], - "Secure": true,
- "Official": true
}数组元素类型 objects or null (IpamConfig) IPAM 配置选项列表,以映射指定: | |||||||||
Array
| |||||||||
| Driver | string or null 使用的 IPAM 驱动名称。 | ||||||||
object or null 驱动专属选项,以映射指定。 | |||||||||
| |||||||||
{- "Driver": "string",
- "Config": [
- {
- "Subnet": "string",
- "IPRange": "string",
- "Gateway": "string",
- "AuxiliaryAddresses": {
- "property1": "string",
- "property2": "string"
}
}
], - "Options": {
- "property1": "string",
- "property2": "string"
}
}object or null | |||
| |||
| Gateway | string or null | ||
| IPRange | string or null | ||
| Subnet | string or null | ||
{- "Subnet": "string",
- "IPRange": "string",
- "Gateway": "string",
- "AuxiliaryAddresses": {
- "property1": "string",
- "property2": "string"
}
}| CreatedAt required | string <date-time> 任务创建时间。 | ||||||||||||||||
required | object (JobSpec) 任务规格。 | ||||||||||||||||
| |||||||||||||||||
required | object (ObjPsStatus) 任务状态。 | ||||||||||||||||
| |||||||||||||||||
| UpdatedAt required | string <date-time> 任务更新时间。 | ||||||||||||||||
{- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}
}| CreatedAt required | string <date-time> 任务创建时间。 | ||||||||||||||||||
| InstanceFailed required | integer >= 0 失败实例数。 | ||||||||||||||||||
| InstanceRunning required | integer >= 0 运行实例数。 | ||||||||||||||||||
required | 数组元素类型 objects (Process) 实例列表。 | ||||||||||||||||||
Array
| |||||||||||||||||||
| InstanceSuccess required | integer >= 0 成功实例数。 | ||||||||||||||||||
| InstanceTotal required | integer >= 0 实例数量。 | ||||||||||||||||||
required | object (JobSpec) 任务规格。 | ||||||||||||||||||
| |||||||||||||||||||
required | object (ObjPsStatus) 任务状态。 | ||||||||||||||||||
| |||||||||||||||||||
| UpdatedAt required | string <date-time> 任务更新时间。 | ||||||||||||||||||
{- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "InstanceTotal": 0,
- "InstanceSuccess": 0,
- "InstanceRunning": 0,
- "InstanceFailed": 0,
- "Spec": {
- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}, - "Instances": [
- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}
]
}required | 数组元素类型 objects (Config) 要运行的容器列表。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or ImagePullPolicy (string) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ImagePullSecret | string or null 拉取镜像时使用的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
object 用户定义的元数据。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Name required | string 任务名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Schedule | string or null 五字段 cron 表达式或支持的快捷形式;参见 [ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Secrets | 数组元素类型 strings or null 作为环境变量加载的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Ttl | integer or null >= 0 执行完成 x 秒后移除任务。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
{- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}required | 数组元素类型 objects (Config) 要运行的容器。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||
null or ImagePullPolicy (string) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ImagePullSecret | string or null 拉取镜像时使用的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
object 用户定义的元数据。 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Name required | string 任务名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Schedule | string or null 任务调度时间(cron)。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Secrets | 数组元素类型 strings or null 作为环境变量加载的 Secret。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Ttl | integer or null >= 0 执行完成 x 秒后移除任务。 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
{- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}| CreatedAt required | string <date-time> 任务创建时间。 | ||||||||||||||||
| InstanceFailed required | integer >= 0 失败实例数。 | ||||||||||||||||
| InstanceRunning required | integer >= 0 运行实例数。 | ||||||||||||||||
| InstanceSuccess required | integer >= 0 成功实例数。 | ||||||||||||||||
| InstanceTotal required | integer >= 0 实例数量。 | ||||||||||||||||
required | object (JobSpec) 任务规格。 | ||||||||||||||||
| |||||||||||||||||
required | object (ObjPsStatus) 任务状态。 | ||||||||||||||||
| |||||||||||||||||
| UpdatedAt required | string <date-time> 任务更新时间。 | ||||||||||||||||
{- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "InstanceTotal": 0,
- "InstanceSuccess": 0,
- "InstanceRunning": 0,
- "InstanceFailed": 0,
- "Spec": {
- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}
}| Rate required | integer >= 0 每秒最大请求数。 |
| Size required | integer >= 0 缓存最大大小,单位 MB。 |
{- "Size": 0,
- "Rate": 0
}此节点当前本地状态,使用枚举值表示。枚举变体不携带数据,可定义为 #[repr(C)],便于 FFI。
"EMPTY"| DisableLogging | boolean or null 禁用此目标的日志。 |
| Key required | string 目标 Cargo 或 VM 的键。 |
| Path | string or null 使用 HTTP 时的目标路径。 |
| Port required | integer <int32> >= 0 目标 Cargo 或 VM 的端口。 |
null or (ProxySsl (ProxySslConfig (object) or ProxySsl (string))) | |
One of null | |
{- "Key": "string",
- "Port": 0,
- "Path": "string",
- "DisableLogging": true,
- "Ssl": { }
}| commit | integer or null <int64> >= 0 |
| commit_peak | integer or null <int64> >= 0 |
| commitbytes | integer or null <int64> >= 0 |
| commitpeakbytes | integer or null <int64> >= 0 |
| failcnt | integer or null <int64> >= 0 |
| limit | integer or null <int64> >= 0 |
| max_usage | integer or null <int64> >= 0 |
| privateworkingset | integer or null <int64> >= 0 |
null or (MemoryStatsStats (MemoryStatsStatsV1 (object) or MemoryStatsStatsV2 (object))) | |
One of null | |
| usage | integer or null <int64> >= 0 |
{- "stats": { },
- "max_usage": 0,
- "usage": 0,
- "failcnt": 0,
- "limit": 0,
- "commit": 0,
- "commit_peak": 0,
- "commitbytes": 0,
- "commitpeakbytes": 0,
- "privateworkingset": 0
}| active_anon required | integer <int64> >= 0 |
| active_file required | integer <int64> >= 0 |
| cache required | integer <int64> >= 0 |
| dirty required | integer <int64> >= 0 |
| hierarchical_memory_limit required | integer <int64> >= 0 |
| hierarchical_memsw_limit | integer or null <int64> >= 0 |
| inactive_anon required | integer <int64> >= 0 |
| inactive_file required | integer <int64> >= 0 |
| mapped_file required | integer <int64> >= 0 |
| pgfault required | integer <int64> >= 0 |
| pgmajfault required | integer <int64> >= 0 |
| pgpgin required | integer <int64> >= 0 |
| pgpgout required | integer <int64> >= 0 |
| rss required | integer <int64> >= 0 |
| rss_huge required | integer <int64> >= 0 |
| shmem | integer or null <int64> >= 0 |
| total_active_anon required | integer <int64> >= 0 |
| total_active_file required | integer <int64> >= 0 |
| total_cache required | integer <int64> >= 0 |
| total_dirty required | integer <int64> >= 0 |
| total_inactive_anon required | integer <int64> >= 0 |
| total_inactive_file required | integer <int64> >= 0 |
| total_mapped_file required | integer <int64> >= 0 |
| total_pgfault required | integer <int64> >= 0 |
| total_pgmajfault required | integer <int64> >= 0 |
| total_pgpgin required | integer <int64> >= 0 |
| total_pgpgout required | integer <int64> >= 0 |
| total_rss required | integer <int64> >= 0 |
| total_rss_huge required | integer <int64> >= 0 |
| total_shmem | integer or null <int64> >= 0 |
| total_unevictable required | integer <int64> >= 0 |
| total_writeback required | integer <int64> >= 0 |
| unevictable required | integer <int64> >= 0 |
| writeback required | integer <int64> >= 0 |
{- "cache": 0,
- "dirty": 0,
- "mapped_file": 0,
- "total_inactive_file": 0,
- "pgpgout": 0,
- "rss": 0,
- "total_mapped_file": 0,
- "writeback": 0,
- "unevictable": 0,
- "pgpgin": 0,
- "total_unevictable": 0,
- "pgmajfault": 0,
- "total_rss": 0,
- "total_rss_huge": 0,
- "total_writeback": 0,
- "total_inactive_anon": 0,
- "rss_huge": 0,
- "hierarchical_memory_limit": 0,
- "total_pgfault": 0,
- "total_active_file": 0,
- "active_anon": 0,
- "total_active_anon": 0,
- "total_pgpgout": 0,
- "total_cache": 0,
- "total_dirty": 0,
- "inactive_anon": 0,
- "active_file": 0,
- "pgfault": 0,
- "inactive_file": 0,
- "total_pgmajfault": 0,
- "total_pgpgin": 0,
- "hierarchical_memsw_limit": 0,
- "shmem": 0,
- "total_shmem": 0
}| active_anon required | integer <int64> >= 0 |
| active_file required | integer <int64> >= 0 |
| cache required | integer <int64> >= 0 |
| dirty required | integer <int64> >= 0 |
| hierarchical_memory_limit required | integer <int64> >= 0 |
| hierarchical_memsw_limit | integer or null <int64> >= 0 |
| inactive_anon required | integer <int64> >= 0 |
| inactive_file required | integer <int64> >= 0 |
| mapped_file required | integer <int64> >= 0 |
| pgfault required | integer <int64> >= 0 |
| pgmajfault required | integer <int64> >= 0 |
| pgpgin required | integer <int64> >= 0 |
| pgpgout required | integer <int64> >= 0 |
| rss required | integer <int64> >= 0 |
| rss_huge required | integer <int64> >= 0 |
| shmem | integer or null <int64> >= 0 |
| total_active_anon required | integer <int64> >= 0 |
| total_active_file required | integer <int64> >= 0 |
| total_cache required | integer <int64> >= 0 |
| total_dirty required | integer <int64> >= 0 |
| total_inactive_anon required | integer <int64> >= 0 |
| total_inactive_file required | integer <int64> >= 0 |
| total_mapped_file required | integer <int64> >= 0 |
| total_pgfault required | integer <int64> >= 0 |
| total_pgmajfault required | integer <int64> >= 0 |
| total_pgpgin required | integer <int64> >= 0 |
| total_pgpgout required | integer <int64> >= 0 |
| total_rss required | integer <int64> >= 0 |
| total_rss_huge required | integer <int64> >= 0 |
| total_shmem | integer or null <int64> >= 0 |
| total_unevictable required | integer <int64> >= 0 |
| total_writeback required | integer <int64> >= 0 |
| unevictable required | integer <int64> >= 0 |
| writeback required | integer <int64> >= 0 |
{- "cache": 0,
- "dirty": 0,
- "mapped_file": 0,
- "total_inactive_file": 0,
- "pgpgout": 0,
- "rss": 0,
- "total_mapped_file": 0,
- "writeback": 0,
- "unevictable": 0,
- "pgpgin": 0,
- "total_unevictable": 0,
- "pgmajfault": 0,
- "total_rss": 0,
- "total_rss_huge": 0,
- "total_writeback": 0,
- "total_inactive_anon": 0,
- "rss_huge": 0,
- "hierarchical_memory_limit": 0,
- "total_pgfault": 0,
- "total_active_file": 0,
- "active_anon": 0,
- "total_active_anon": 0,
- "total_pgpgout": 0,
- "total_cache": 0,
- "total_dirty": 0,
- "inactive_anon": 0,
- "active_file": 0,
- "pgfault": 0,
- "inactive_file": 0,
- "total_pgmajfault": 0,
- "total_pgpgin": 0,
- "hierarchical_memsw_limit": 0,
- "shmem": 0,
- "total_shmem": 0
}| active_anon required | integer <int64> >= 0 |
| active_file required | integer <int64> >= 0 |
| anon required | integer <int64> >= 0 |
| anon_thp required | integer <int64> >= 0 |
| file required | integer <int64> >= 0 |
| file_dirty required | integer <int64> >= 0 |
| file_mapped required | integer <int64> >= 0 |
| file_writeback required | integer <int64> >= 0 |
| inactive_anon required | integer <int64> >= 0 |
| inactive_file required | integer <int64> >= 0 |
| kernel_stack required | integer <int64> >= 0 |
| pgactivate required | integer <int64> >= 0 |
| pgdeactivate required | integer <int64> >= 0 |
| pgfault required | integer <int64> >= 0 |
| pglazyfree required | integer <int64> >= 0 |
| pglazyfreed required | integer <int64> >= 0 |
| pgmajfault required | integer <int64> >= 0 |
| pgrefill required | integer <int64> >= 0 |
| pgscan required | integer <int64> >= 0 |
| pgsteal required | integer <int64> >= 0 |
| shmem required | integer <int64> >= 0 |
| slab required | integer <int64> >= 0 |
| slab_reclaimable required | integer <int64> >= 0 |
| slab_unreclaimable required | integer <int64> >= 0 |
| sock required | integer <int64> >= 0 |
| thp_collapse_alloc required | integer <int64> >= 0 |
| thp_fault_alloc required | integer <int64> >= 0 |
| unevictable required | integer <int64> >= 0 |
| workingset_activate required | integer <int64> >= 0 |
| workingset_nodereclaim required | integer <int64> >= 0 |
| workingset_refault required | integer <int64> >= 0 |
{- "anon": 0,
- "file": 0,
- "kernel_stack": 0,
- "slab": 0,
- "sock": 0,
- "shmem": 0,
- "file_mapped": 0,
- "file_dirty": 0,
- "file_writeback": 0,
- "anon_thp": 0,
- "inactive_anon": 0,
- "active_anon": 0,
- "inactive_file": 0,
- "active_file": 0,
- "unevictable": 0,
- "slab_reclaimable": 0,
- "slab_unreclaimable": 0,
- "pgfault": 0,
- "pgmajfault": 0,
- "workingset_refault": 0,
- "workingset_activate": 0,
- "workingset_nodereclaim": 0,
- "pgrefill": 0,
- "pgscan": 0,
- "pgsteal": 0,
- "pgactivate": 0,
- "pgdeactivate": 0,
- "pglazyfree": 0,
- "pglazyfreed": 0,
- "thp_fault_alloc": 0,
- "thp_collapse_alloc": 0
}| CreatedAt required | string <date-time> 指标创建时间。 |
| Data required | any 指标数据。 |
| ExpiresAt required | string <date-time> 指标到期时间。 |
| Key required | string <uuid> 数据库中指标的键,类型为 |
| Kind required | string 指标类型。 |
| NodeName required | string 指标来源节点。 |
| Note | string or null 指标的可选备注。 |
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ExpiresAt": "2019-08-24T14:15:22Z",
- "NodeName": "string",
- "Kind": "string",
- "Data": null,
- "Note": "string"
}| Data required | any 指标数据。 |
| Kind required | string 指标类型。 |
| Note | string or null 指标的可选备注。 |
{- "Kind": "string",
- "Data": null,
- "Note": "string"
}null or MountBindOptions (object) | |
One of null | |
| Consistency | string or null 挂载一致性要求: |
| ReadOnly | boolean or null 挂载是否应为只读。 |
| Source | string or null 挂载源,例如卷名称或主机路径。 |
| Target | string or null 容器路径。 |
null or MountTmpfsOptions (object) | |
One of null | |
null or MountTypeEnum (string) | |
One of null | |
null or MountVolumeOptions (object) | |
One of null | |
{- "Target": "string",
- "Source": "string",
- "Type": { },
- "ReadOnly": true,
- "Consistency": "string",
- "BindOptions": { },
- "VolumeOptions": { },
- "TmpfsOptions": { }
}| CreateMountpoint | boolean or null 主机挂载点缺失时创建。 |
| NonRecursive | boolean or null 禁用递归绑定挂载。 |
null or MountBindOptionsPropagationEnum (string) | |
One of null | |
| ReadOnlyForceRecursive | boolean or null 无法将挂载设为递归只读时返回错误。 |
| ReadOnlyNonRecursive | boolean or null 让挂载自身只读而非递归只读,但仍保留递归挂载(除非同时将 NonRecursive 设为 |
{- "Propagation": { },
- "NonRecursive": true,
- "CreateMountpoint": true,
- "ReadOnlyNonRecursive": true,
- "ReadOnlyForceRecursive": true
}"EMPTY"| Destination | string or null Destination 是相对于容器根目录( |
| Driver | string or null Driver 是创建卷使用的卷驱动(当挂载类型为卷时)。 |
| Mode | string or null Mode 是创建绑定挂载或卷挂载时用户提供的逗号分隔选项。默认值因平台而异(Linux 为 |
| Name | string or null Name 是 |
| Propagation | string or null Propagation 描述挂载如何从主机传播到挂载点,以及反向传播方式。详情见 Linux 内核文档。Windows 不使用此字段。 |
| RW | boolean or null 挂载是否可写,即读写挂载。 |
| Source | string or null 挂载源位置。卷挂载保存卷的存储位置(在 |
null or MountPointTypeEnum (string) | |
One of null | |
{- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}"EMPTY"| Mode | integer or null <int64> tmpfs 挂载的权限模式,以整数表示。 |
| SizeBytes | integer or null <int64> tmpfs 挂载大小,单位字节。 |
{- "SizeBytes": 0,
- "Mode": 0
}null or MountVolumeOptionsDriverConfig (object) | |||
One of null | |||
object or null 用户定义的键值元数据。 | |||
| |||
| NoCopy | boolean or null 使用目标数据填充卷。 | ||
| Subpath | string or null 卷内的源路径,必须是相对路径,且不能包含向父目录回退的片段。 | ||
{- "NoCopy": true,
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "DriverConfig": { },
- "Subpath": "string"
}| Name | string or null 创建卷所用驱动名称。 | ||
object or null 驱动专属选项的键值映射。 | |||
| |||
{- "Name": "string",
- "Options": {
- "property1": "string",
- "property2": "string"
}
}| CreatedAt required | string <date-time> 命名空间创建时间。 |
| Metadata | any 用户定义的元数据。 |
| Name required | string 作为命名空间主键的名称。 |
{- "Name": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Metadata": null
}required | 数组元素类型 objects (CargoInspect) Cargo 数量。 | ||||||||||||||
Array
| |||||||||||||||
| Name required | string 命名空间名称。 | ||||||||||||||
{- "Name": "string",
- "Cargoes": [
- {
- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CargoKey": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}, - "Instances": [
- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}
]
}
]
}| Metadata | any 用户定义的元数据。 |
| Name required | string 命名空间名称。 |
{- "Name": "string",
- "Metadata": null
}| Cargoes required | integer >= 0 Cargo 数量。 |
| CreatedAt required | string <date-time> 命名空间创建时间。 |
| Instances required | integer >= 0 实例数量。 |
| Name required | string 命名空间名称。 |
{- "Name": "string",
- "Cargoes": 0,
- "Instances": 0,
- "CreatedAt": "2019-08-24T14:15:22Z"
}| Attachable | boolean or null | ||
object or null | |||
| |||
null or String (string) | |||
One of null | |||
| Driver | string or null | ||
| EnableIPv6 | boolean or null | ||
| Id | string or null | ||
| Ingress | boolean or null | ||
| Internal | boolean or null | ||
null or Ipam (object) | |||
One of null | |||
object or null | |||
| |||
| Name | string or null | ||
object or null | |||
| |||
| Scope | string or null | ||
{- "Name": "string",
- "Id": "string",
- "Created": { },
- "Scope": "string",
- "Driver": "string",
- "EnableIPv6": true,
- "IPAM": { },
- "Internal": true,
- "Attachable": true,
- "Ingress": true,
- "Containers": {
- "property1": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}, - "property2": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}
}, - "Options": {
- "property1": "string",
- "property2": "string"
}, - "Labels": {
- "property1": "string",
- "property2": "string"
}
}| EndpointID | string or null |
| IPv4Address | string or null |
| IPv6Address | string or null |
| MacAddress | string or null |
| Name | string or null |
{- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}| Bridge | string or null 设置 dockerd 的 --bridge 参数时,默认桥接接口名称。 | ||||
| EndpointID | string or null EndpointID 唯一标识沙箱中的服务端点。 Networks 映射中的 "bridge" 网络信息,它包含相同信息。此字段在 Docker 1.9 弃用,计划在 Docker 17.12.0 移除。
| ||||
| Gateway | string or null 默认 "bridge" 网络的网关地址。 Networks 映射中的 "bridge" 网络信息,它包含相同信息。此字段在 Docker 1.9 弃用,计划在 Docker 17.12.0 移除。
| ||||
| GlobalIPv6Address | string or null 默认 "bridge" 网络的全局 IPv6 地址。 Networks 映射中的 "bridge" 网络信息,它包含相同信息。此字段在 Docker 1.9 弃用,计划在 Docker 17.12.0 移除。
| ||||
| GlobalIPv6PrefixLen | integer or null <int64> 全局 IPv6 地址掩码长度。 Networks 映射中的 "bridge" 网络信息,它包含相同信息。此字段在 Docker 1.9 弃用,计划在 Docker 17.12.0 移除。
| ||||
| HairpinMode | boolean or null 表示虚拟接口是否启用 hairpin NAT。已弃用:此字段从不设置,将在后续版本移除。 | ||||
| IPAddress | string or null 默认 "bridge" 网络的 IPv4 地址。 Networks 映射中的 "bridge" 网络信息,它包含相同信息。此字段在 Docker 1.9 弃用,计划在 Docker 17.12.0 移除。
| ||||
| IPPrefixLen | integer or null <int64> IPv4 地址掩码长度。 Networks 映射中的 "bridge" 网络信息,它包含相同信息。此字段在 Docker 1.9 弃用,计划在 Docker 17.12.0 移除。
| ||||
| IPv6Gateway | string or null 此网络的 IPv6 网关地址。 Networks 映射中的 "bridge" 网络信息,它包含相同信息。此字段在 Docker 1.9 弃用,计划在 Docker 17.12.0 移除。
| ||||
| LinkLocalIPv6Address | string or null 使用链路本地前缀的 IPv6 单播地址。已弃用:此字段从不设置,将在后续版本移除。 | ||||
| LinkLocalIPv6PrefixLen | integer or null <int64> IPv6 单播地址的前缀长度。已弃用:此字段从不设置,将在后续版本移除。 | ||||
| MacAddress | string or null 默认 "bridge" 网络上容器的 MAC 地址。 Networks 映射中的 "bridge" 网络信息,它包含相同信息。此字段在 Docker 1.9 弃用,计划在 Docker 17.12.0 移除。
| ||||
object or null 容器连接的全部网络的信息。 | |||||
| |||||
null or HashMap (object) | |||||
One of null | |||||
| SandboxID | string or null SandboxID 唯一标识容器网络栈。 | ||||
| SandboxKey | string or null SandboxKey 是 netns 句柄的完整路径。 | ||||
数组元素类型 objects or null (Address) 已弃用:此字段从不设置,将在后续版本移除。 | |||||
Array
| |||||
数组元素类型 objects or null (Address) 已弃用:此字段从不设置,将在后续版本移除。 | |||||
Array
| |||||
{- "Bridge": "string",
- "SandboxID": "string",
- "HairpinMode": true,
- "LinkLocalIPv6Address": "string",
- "LinkLocalIPv6PrefixLen": 0,
- "Ports": { },
- "SandboxKey": "string",
- "SecondaryIPAddresses": [
- {
- "Addr": "string",
- "PrefixLen": 0
}
], - "SecondaryIPv6Addresses": [
- {
- "Addr": "string",
- "PrefixLen": 0
}
], - "EndpointID": "string",
- "Gateway": "string",
- "GlobalIPv6Address": "string",
- "GlobalIPv6PrefixLen": 0,
- "IPAddress": "string",
- "IPPrefixLen": 0,
- "IPv6Gateway": "string",
- "MacAddress": "string",
- "Networks": {
- "property1": {
- "IPAMConfig": { },
- "Links": [
- "string"
], - "MacAddress": "string",
- "Aliases": [
- "string"
], - "NetworkID": "string",
- "EndpointID": "string",
- "Gateway": "string",
- "IPAddress": "string",
- "IPPrefixLen": 0,
- "IPv6Gateway": "string",
- "GlobalIPv6Address": "string",
- "GlobalIPv6PrefixLen": 0,
- "DriverOpts": {
- "property1": "string",
- "property2": "string"
}, - "DNSNames": [
- "string"
]
}, - "property2": {
- "IPAMConfig": { },
- "Links": [
- "string"
], - "MacAddress": "string",
- "Aliases": [
- "string"
], - "NetworkID": "string",
- "EndpointID": "string",
- "Gateway": "string",
- "IPAddress": "string",
- "IPPrefixLen": 0,
- "IPv6Gateway": "string",
- "GlobalIPv6Address": "string",
- "GlobalIPv6PrefixLen": 0,
- "DriverOpts": {
- "property1": "string",
- "property2": "string"
}, - "DNSNames": [
- "string"
]
}
}
}| rx_bytes required | integer <int64> >= 0 |
| rx_dropped required | integer <int64> >= 0 |
| rx_errors required | integer <int64> >= 0 |
| rx_packets required | integer <int64> >= 0 |
| tx_bytes required | integer <int64> >= 0 |
| tx_dropped required | integer <int64> >= 0 |
| tx_errors required | integer <int64> >= 0 |
| tx_packets required | integer <int64> >= 0 |
{- "rx_dropped": 0,
- "rx_bytes": 0,
- "rx_errors": 0,
- "tx_packets": 0,
- "tx_dropped": 0,
- "rx_packets": 0,
- "tx_errors": 0,
- "tx_bytes": 0
}required | object | ||
| |||
{- "EndpointsConfig": {
- "property1": {
- "IPAMConfig": { },
- "Links": [
- "string"
], - "MacAddress": "string",
- "Aliases": [
- "string"
], - "NetworkID": "string",
- "EndpointID": "string",
- "Gateway": "string",
- "IPAddress": "string",
- "IPPrefixLen": 0,
- "IPv6Gateway": "string",
- "GlobalIPv6Address": "string",
- "GlobalIPv6PrefixLen": 0,
- "DriverOpts": {
- "property1": "string",
- "property2": "string"
}, - "DNSNames": [
- "string"
]
}, - "property2": {
- "IPAMConfig": { },
- "Links": [
- "string"
], - "MacAddress": "string",
- "Aliases": [
- "string"
], - "NetworkID": "string",
- "EndpointID": "string",
- "Gateway": "string",
- "IPAddress": "string",
- "IPPrefixLen": 0,
- "IPv6Gateway": "string",
- "GlobalIPv6Address": "string",
- "GlobalIPv6PrefixLen": 0,
- "DriverOpts": {
- "property1": "string",
- "property2": "string"
}, - "DNSNames": [
- "string"
]
}
}
}| CreatedAt required | string <date-time> 创建时间。 |
| Endpoint required | string 连接节点的端点。 |
| Metadata | any 用户定义的元数据。 |
| Name required | string 节点名称。 |
| Version required | string 节点版本。 |
{- "Name": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Endpoint": "string",
- "Version": "string",
- "Metadata": null
}| Key required | string 约束键(如 "region"、"label"、"group" 等)。 |
| Operator required | string (ConstraintOp) 枚举值: "Eq" "Ne" 约束运算符(Eq/Ne)。 |
| Value required | string 约束值。 |
{- "Key": "string",
- "Operator": "Eq",
- "Value": "string"
}| Actual required | string (ObjPsStatusKind) 枚举值: "create" "starting" "start" "updating" "update" "destroying" "destroy" "stopping" "stop" "fail" "finish" "unknown" |
| Health required | string (ObjPsHealthStatusKind) 枚举值: "healthy" "unhealthy" "unknown" |
| PrevActual required | string (ObjPsStatusKind) 枚举值: "create" "starting" "start" "updating" "update" "destroying" "destroy" "stopping" "stop" "fail" "finish" "unknown" |
| PrevWanted required | string (ObjPsStatusKind) 枚举值: "create" "starting" "start" "updating" "update" "destroying" "destroy" "stopping" "stop" "fail" "finish" "unknown" |
| UpdatedAt required | string <date-time> |
| Wanted required | string (ObjPsStatusKind) 枚举值: "create" "starting" "start" "updating" "update" "destroying" "destroy" "stopping" "stop" "fail" "finish" "unknown" |
{- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}"create"| Addr | string or null 访问此节点的 IP 地址和端口。 |
| NodeID | string or null 节点在 Swarm 中的唯一标识。 |
{- "NodeID": "string",
- "Addr": "string"
}| current | integer or null <int64> >= 0 |
| limit | integer or null <int64> >= 0 |
{- "current": 0,
- "limit": 0
}| Authorization | 数组元素类型 strings or null 可用授权插件名称。 |
| Log | 数组元素类型 strings or null 可用日志驱动和日志驱动插件名称。 |
| Network | 数组元素类型 strings or null 可用网络驱动和网络驱动插件名称。 |
| Volume | 数组元素类型 strings or null 可用卷驱动和网络驱动插件名称。 |
{- "Volume": [
- "string"
], - "Network": [
- "string"
], - "Authorization": [
- "string"
], - "Log": [
- "string"
]
}| CreatedAt required | string <date-time> 创建时间。 | ||||||||||||||||||||||||||||||||||||||||||||||||||
required | object (ContainerInspectResponse) 进程数据,类型为 ContainerInspect。 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||
| IpAddress | string or null 从最近观察到的进程状态解析的有效 IP 地址。 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| Key required | string 进程键。 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| Kind required | string (ProcessKind) 枚举值: "vm" "job" "cargo" 进程类型(Job、Vm、Cargo)。 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| KindKey required | string Cargo 和 VM 的规范资源键;任务使用名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| Name required | string 进程名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| NodeName required | string 容器运行所在节点的名称。 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| UpdatedAt required | string <date-time> 实例最近更新时间。 | ||||||||||||||||||||||||||||||||||||||||||||||||||
{- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}| AttachStderr | boolean or null 连接标准错误。 |
| AttachStdin | boolean or null 连接标准输入。 |
| AttachStdout | boolean or null 连接标准输出。 |
| Cmd | 数组元素类型 strings or null 要执行的命令及参数。 |
| DetachKeys | string or null 兼容 Docker 的分离按键序列。 |
| Env | 数组元素类型 strings or null 环境变量,格式为 |
| Privileged | boolean or null 以扩展权限运行命令。 |
| Tty | boolean or null 分配伪终端。 |
| User | string or null 命令使用的用户和可选用户组。 |
| WorkingDir | string or null 进程内部工作目录。 |
{- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "Tty": true,
- "DetachKeys": "string",
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Privileged": true,
- "User": "string",
- "WorkingDir": "string"
}| Name required | string | ||||||||||||||||||||||||||
required | object (Stats) 容器统计。 | ||||||||||||||||||||||||||
| |||||||||||||||||||||||||||
{- "Name": "string",
- "Stats": {
- "read": "string",
- "preread": "string",
- "num_procs": 0,
- "pids_stats": {
- "current": 0,
- "limit": 0
}, - "network": { },
- "networks": {
- "property1": {
- "rx_dropped": 0,
- "rx_bytes": 0,
- "rx_errors": 0,
- "tx_packets": 0,
- "tx_dropped": 0,
- "rx_packets": 0,
- "tx_errors": 0,
- "tx_bytes": 0
}, - "property2": {
- "rx_dropped": 0,
- "rx_bytes": 0,
- "rx_errors": 0,
- "tx_packets": 0,
- "tx_dropped": 0,
- "rx_packets": 0,
- "tx_errors": 0,
- "tx_bytes": 0
}
}, - "memory_stats": {
- "stats": { },
- "max_usage": 0,
- "usage": 0,
- "failcnt": 0,
- "limit": 0,
- "commit": 0,
- "commit_peak": 0,
- "commitbytes": 0,
- "commitpeakbytes": 0,
- "privateworkingset": 0
}, - "blkio_stats": {
- "io_service_bytes_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_serviced_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_queue_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_service_time_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_wait_time_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_merged_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_time_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "sectors_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
]
}, - "cpu_stats": {
- "cpu_usage": {
- "percpu_usage": [
- 0
], - "usage_in_usermode": 0,
- "total_usage": 0,
- "usage_in_kernelmode": 0
}, - "system_cpu_usage": 0,
- "online_cpus": 0,
- "throttling_data": {
- "periods": 0,
- "throttled_periods": 0,
- "throttled_time": 0
}
}, - "precpu_stats": {
- "cpu_usage": {
- "percpu_usage": [
- 0
], - "usage_in_usermode": 0,
- "total_usage": 0,
- "usage_in_kernelmode": 0
}, - "system_cpu_usage": 0,
- "online_cpus": 0,
- "throttling_data": {
- "periods": 0,
- "throttled_periods": 0,
- "throttled_time": 0
}
}, - "storage_stats": {
- "read_count_normalized": 0,
- "read_size_bytes": 0,
- "write_count_normalized": 0,
- "write_size_bytes": 0
}, - "name": "string",
- "id": "string"
}
}| ActiveConnectionIdLimit | integer or null >= 0 QUIC 的 active_connection_id_limit 传输参数。 |
| Bpf | boolean or null 使用 eBPF 路由 QUIC 数据包(Linux 5.7+)。 |
| Gso | boolean or null 为 QUIC 启用通用分段卸载(Linux 的 UDP_SEGMENT)。 |
| HostKey | string or null QUIC 主机密钥文件路径。 |
| Hq | boolean or null 启用 QUIC 互操作测试使用的 HTTP/0.9 协议协商。 |
| MaxConcurrentStreams | integer or null >= 0 每个连接的最大并发 HTTP/3 流数。 |
| Retry | boolean or null 启用 QUIC 地址验证(重试)。 |
| StreamBufferSize | string or null QUIC 流缓冲大小(如 "64k"、"8k")。 |
{- "Hq": true,
- "MaxConcurrentStreams": 0,
- "StreamBufferSize": "string",
- "ActiveConnectionIdLimit": 0,
- "Bpf": true,
- "Gso": true,
- "HostKey": "string",
- "Retry": true
}| AllowedIps | 数组元素类型 strings or null 允许的 IP 地址。 | ||||||||||
null or ProxyCache (string) | |||||||||||
One of null | |||||||||||
null or NginxDuration (string) | |||||||||||
One of null | |||||||||||
null or NginxSize (string) | |||||||||||
One of null | |||||||||||
null or NginxDuration (string) | |||||||||||
One of null | |||||||||||
| Headers | 数组元素类型 strings or null 要添加的附加请求头。 | ||||||||||
| InterceptErrors | boolean or null 拦截上游错误。 | ||||||||||
null or LimitReq (object) | |||||||||||
One of null | |||||||||||
null or ProxyNextUpstream (string) | |||||||||||
One of null | |||||||||||
| Path required | string 路径。 | ||||||||||
null or NginxDuration (string) | |||||||||||
One of null | |||||||||||
| RequestBuffering | boolean or null 缓冲客户端请求体。 | ||||||||||
| ResponseBuffering | boolean or null 缓冲上游响应。 | ||||||||||
null or NginxDuration (string) | |||||||||||
One of null | |||||||||||
required | object or object or object (LocationTarget) | ||||||||||
One of
| |||||||||||
| Version | number or null <double> 使用的 HTTP 版本。 | ||||||||||
{- "Path": "string",
- "Target": {
- "Key": "string",
- "Port": 0,
- "Path": "string",
- "DisableLogging": true,
- "Ssl": { }
}, - "LimitReq": { },
- "AllowedIps": [
- "string"
], - "Headers": [
- "string"
], - "Version": 0,
- "ClientMaxBodySize": { },
- "ClientBodyTimeout": { },
- "RequestBuffering": true,
- "ResponseBuffering": true,
- "Cache": { },
- "ReadTimeout": { },
- "SendTimeout": { },
- "ConnectTimeout": { },
- "NextUpstream": { },
- "InterceptErrors": true
}| Domain | string or null 域名。 | ||||||||||||||||||||||||||||||||
null or (Hsts (Hsts (string) or Hsts (string) or Hsts (object))) | |||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||
null or (ProxyHttp3 (ProxyHttp3 (boolean) or ProxyHttp3Config (object))) | |||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||
| Includes | 数组元素类型 strings or null 要包含的额外配置文件路径。 | ||||||||||||||||||||||||||||||||
null or LimitReqZone (object) | |||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||
required | 数组元素类型 objects (ProxyHttpLocation) 处理多个路径的 location。 | ||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||
required | string or object or object (NetworkKind) | ||||||||||||||||||||||||||||||||
One of string 网络绑定类型。 | |||||||||||||||||||||||||||||||||
| Port | integer or null <int32> >= 0 监听端口(默认 80 或 443)。 | ||||||||||||||||||||||||||||||||
null or (ProxySsl (ProxySslConfig (object) or ProxySsl (string))) | |||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||
{- "Domain": "string",
- "Port": 0,
- "Hsts": { },
- "Network": "string",
- "LimitReqZone": { },
- "Locations": [
- {
- "Path": "string",
- "Target": {
- "Key": "string",
- "Port": 0,
- "Path": "string",
- "DisableLogging": true,
- "Ssl": { }
}, - "LimitReq": { },
- "AllowedIps": [
- "string"
], - "Headers": [
- "string"
], - "Version": 0,
- "ClientMaxBodySize": { },
- "ClientBodyTimeout": { },
- "RequestBuffering": true,
- "ResponseBuffering": true,
- "Cache": { },
- "ReadTimeout": { },
- "SendTimeout": { },
- "ConnectTimeout": { },
- "NextUpstream": { },
- "InterceptErrors": true
}
], - "Ssl": { },
- "Http3": { },
- "Includes": [
- "string"
]
}| Domain | string or null 域名。 | ||||||||||||||||||||||||||||||||
null or (Hsts (Hsts (string) or Hsts (string) or Hsts (object))) | |||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||
null or (ProxyHttp3 (ProxyHttp3 (boolean) or ProxyHttp3Config (object))) | |||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||
| Includes | 数组元素类型 strings or null 要包含的额外配置文件路径。 | ||||||||||||||||||||||||||||||||
null or LimitReqZone (object) | |||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||
required | 数组元素类型 objects (ProxyHttpLocation) 处理多个路径的 location。 | ||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||
required | string or object or object (NetworkKind) | ||||||||||||||||||||||||||||||||
One of string 网络绑定类型。 | |||||||||||||||||||||||||||||||||
| Port | integer or null <int32> >= 0 监听端口(默认 80 或 443)。 | ||||||||||||||||||||||||||||||||
null or (ProxySsl (ProxySslConfig (object) or ProxySsl (string))) | |||||||||||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||||||||||
{- "Domain": "string",
- "Port": 0,
- "Hsts": { },
- "Network": "string",
- "LimitReqZone": { },
- "Locations": [
- {
- "Path": "string",
- "Target": {
- "Key": "string",
- "Port": 0,
- "Path": "string",
- "DisableLogging": true,
- "Ssl": { }
}, - "LimitReq": { },
- "AllowedIps": [
- "string"
], - "Headers": [
- "string"
], - "Version": 0,
- "ClientMaxBodySize": { },
- "ClientBodyTimeout": { },
- "RequestBuffering": true,
- "ResponseBuffering": true,
- "Cache": { },
- "ReadTimeout": { },
- "SendTimeout": { },
- "ConnectTimeout": { },
- "NextUpstream": { },
- "InterceptErrors": true
}
], - "Ssl": { },
- "Http3": { },
- "Includes": [
- "string"
]
}required | string or object or object (NetworkKind) | ||||||||||
One of string 网络绑定类型。 | |||||||||||
| Port required | integer <int32> >= 0 节点上要开放的端口。 | ||||||||||
| Protocol required | string (ProxyStreamProtocol) 枚举值: "Tcp" "Udp" 使用的协议:Tcp 或 Udp。 | ||||||||||
null or (ProxySsl (ProxySslConfig (object) or ProxySsl (string))) | |||||||||||
One of null | |||||||||||
required | object or object or object (StreamTarget) | ||||||||||
One of
| |||||||||||
{- "Network": "string",
- "Protocol": "Tcp",
- "Port": 0,
- "Ssl": { },
- "Target": {
- "Key": "string",
- "Port": 0,
- "Path": "string",
- "DisableLogging": true,
- "Ssl": { }
}
}| Certificate required | string 在 TLS Secret 中保存的证书内容。 |
| CertificateClient | string or null 在 TLS Secret 中保存的证书颁发机构内容。 |
| CertificateKey required | string 在 TLS Secret 中保存的私钥内容。 |
| Dhparam | string or null 在 TLS Secret 中保存的 DH 参数内容。 |
| VerifyClient | boolean or null 启用或禁用客户端验证。 |
{- "Certificate": "string",
- "CertificateKey": "string",
- "CertificateClient": "string",
- "VerifyClient": true,
- "Dhparam": "string"
}| Certificate required | string 在 TLS Secret 中保存的证书内容。 |
| CertificateClient | string or null 在 TLS Secret 中保存的证书颁发机构内容。 |
| CertificateKey required | string 在 TLS Secret 中保存的私钥内容。 |
| Dhparam | string or null 在 TLS Secret 中保存的 DH 参数内容。 |
| VerifyClient | boolean or null 启用或禁用客户端验证。 |
{- "Certificate": "string",
- "CertificateKey": "string",
- "CertificateClient": "string",
- "VerifyClient": true,
- "Dhparam": "string"
}| AllowNondistributableArtifactsCIDRs | 数组元素类型 strings or null 允许推送不可分发内容的 IP 范围列表,使用 CIDR 语法 RFC 4632。某些镜像(如 Windows 基础镜像)包含受许可证分发限制的内容,推送镜像时通常不包含这些内容。此配置覆盖该行为,允许向解析 IP 位于指定 CIDR 子网内的仓库推送不可分发内容。隔离网络中的仓库可以借此保存镜像,让主机无需连接其他服务器即可拉取。> 警告:不可分发内容通常对分发和共享方式、位置有限制。仅向私有仓库推送,并确保遵守相关再分发条款。 | ||
| AllowNondistributableArtifactsHostnames | 数组元素类型 strings or null 允许推送不可分发内容的仓库主机名列表,格式为 | ||
object or null | |||
| |||
| InsecureRegistryCIDRs | 数组元素类型 strings or null 不安全镜像仓库的 IP 范围列表,使用 CIDR 语法(RFC 4632)。不安全仓库允许未加密的 HTTP,或不可信的 HTTPS(未知 CA 证书)通信。默认本地仓库( | ||
| Mirrors | 数组元素类型 strings or null 作为官方 | ||
{- "AllowNondistributableArtifactsCIDRs": [
- "string"
], - "AllowNondistributableArtifactsHostnames": [
- "string"
], - "InsecureRegistryCIDRs": [
- "string"
], - "IndexConfigs": {
- "property1": {
- "Name": "string",
- "Mirrors": [
- "string"
], - "Secure": true,
- "Official": true
}, - "property2": {
- "Name": "string",
- "Mirrors": [
- "string"
], - "Secure": true,
- "Official": true
}
}, - "Mirrors": [
- "string"
]
}| CreatedAt required | string <date-time> 资源创建时间。 | ||||||||||||
| Kind required | string 资源类型。 | ||||||||||||
required | object (ResourceSpec) 资源规格。 | ||||||||||||
| |||||||||||||
{- "Kind": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ResourceKey": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}
}required | 数组元素类型 objects (DnsEntry) | ||||
Array
| |||||
required | string or object or object (NetworkKind) | ||||
One of string 网络绑定选择器。 | |||||
{- "Network": "string",
- "Entries": [
- {
- "Name": "string",
- "IpAddress": "string"
}
]
}| CreatedAt required | string <date-time> 类型创建时间。 | ||||
required | object (ResourceKindSpec) 类型创建时间。 | ||||
| |||||
| Metadata | any 类型创建时间。 | ||||
| Name required | string 类型名称。 | ||||
| Version required | string 类型创建时间。 | ||||
{- "Name": "string",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Metadata": null,
- "Data": {
- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}
}| CreatedAt required | string <date-time> 类型创建时间。 | ||||||||||||
| Name required | string 类型名称。 | ||||||||||||
required | 数组元素类型 objects (ResourceKindVersion) 可用版本列表。 | ||||||||||||
Array
| |||||||||||||
{- "Name": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Versions": [
- {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "KindKey": "string",
- "Version": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}
}
]
}required | object (ResourceKindSpec) 资源类型规格。 | ||||
| |||||
object 资源类型的用户定义元数据。 | |||||
| |||||
| Name required | string 资源类型名称。 | ||||
| Version required | string 资源类型版本。 | ||||
{- "Name": "string",
- "Version": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}
}object 此类型和版本资源的 JSONSchema。 | |||
| |||
| Url | string or null 创建、更新或删除此类型和版本的资源时调用的服务。 | ||
{- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}| CreatedAt required | string <date-time> 版本创建时间。 | ||||
required | object (ResourceKindSpec) 类型规格。 | ||||
| |||||
| Key required | string <uuid> 版本键。 | ||||
| KindKey required | string 与此版本关联的类型。 | ||||
object 用户定义的元数据。 | |||||
| |||||
| Version required | string 版本。 | ||||
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "KindKey": "string",
- "Version": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "Schema": {
- "property1": "string",
- "property2": "string"
}, - "Url": "string"
}
}required | object 资源数据,JSON 对象。 | ||
| |||
| Kind required | string 资源类型。 | ||
object 资源的用户定义元数据。 | |||
| |||
| Name required | string 资源名称。 | ||
{- "Name": "string",
- "Kind": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}required | 数组元素类型 ProxyRuleHttp (object) or ProxyRuleStream (object) (ProxyRule) 要应用的规则。 | ||||||||||||||||||
Array One of
| |||||||||||||||||||
{- "Rules": [
- {
- "Domain": "string",
- "Port": 0,
- "Hsts": { },
- "Network": "string",
- "LimitReqZone": { },
- "Locations": [
- {
- "Path": "string",
- "Target": {
- "Key": "string",
- "Port": 0,
- "Path": "string",
- "DisableLogging": true,
- "Ssl": { }
}, - "LimitReq": { },
- "AllowedIps": [
- "string"
], - "Headers": [
- "string"
], - "Version": 0,
- "ClientMaxBodySize": { },
- "ClientBodyTimeout": { },
- "RequestBuffering": true,
- "ResponseBuffering": true,
- "Cache": { },
- "ReadTimeout": { },
- "SendTimeout": { },
- "ConnectTimeout": { },
- "NextUpstream": { },
- "InterceptErrors": true
}
], - "Ssl": { },
- "Http3": { },
- "Includes": [
- "string"
]
}
]
}| CreatedAt required | string <date-time> 资源创建时间。 | ||
required | object 以 JSON 对象表示的资源数据。 | ||
| |||
| Key required | string <uuid> 资源键。 | ||
object 资源的用户定义元数据。 | |||
| |||
| ResourceKey required | string 与数据关联的资源键。 | ||
| Version required | string 资源版本。 | ||
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Version": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "ResourceKey": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}required | object 以 JSON 对象表示的资源规格。 | ||
| |||
object 以 JSON 对象表示的资源元数据。 | |||
| |||
{- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}| Path | string or null |
| Weight | integer or null >= 0 |
{- "Path": "string",
- "Weight": 0
}| Hard | integer or null <int64> 硬限制。 |
| Name | string or null ulimit 名称。 |
| Soft | integer or null <int64> 软限制。 |
{- "Name": "string",
- "Soft": 0,
- "Hard": 0
}| MaximumRetryCount | integer or null <int64> 使用 |
null or RestartPolicyNameEnum (string) | |
One of null | |
{- "Name": { },
- "MaximumRetryCount": 0
}"EMPTY"| path | string or null OCI 可执行二进制文件名称及可选路径。省略路径时,守护进程搜索主机 | ||
| runtimeArgs | 数组元素类型 strings or null 调用运行时时传入的命令行参数列表。 | ||
object or null 运行时专属信息。本 API 规范不定义各运行时提供的数据,但运行时可能提供以下已知属性: | |||
| |||
{- "path": "string",
- "runtimeArgs": [
- "string"
], - "status": {
- "property1": "string",
- "property2": "string"
}
}| CreatedAt required | string <date-time> 创建时间。 | ||
required | object Secret 数据。 | ||
| |||
| Immutable required | boolean 无法更新 Secret。 | ||
| Kind required | string Secret 类型。 | ||
object | |||
| |||
| Name required | string Secret 名称。 | ||
| UpdatedAt required | string <date-time> 最近更新时间。 | ||
{- "Name": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Kind": "string",
- "Immutable": true,
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}required | object Secret 数据。 | ||
| |||
| Immutable | boolean 无法更新 Secret。 | ||
| Kind required | string Secret 类型。 | ||
object 资源的用户定义元数据。 | |||
| |||
| Name required | string Secret 名称。 | ||
{- "Name": "string",
- "Kind": "string",
- "Immutable": true,
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}required | object 以 JSON 对象表示的 Secret 数据。 | ||
| |||
object Secret 的用户定义元数据。 | |||
| |||
{- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}| Cert | string or null 证书内容。 |
| CertCa | string or null 证书颁发机构内容。 |
| CertKey | string or null 证书私钥内容。 |
| Password | string or null 证书密码(如果有)。 |
| Verify required | boolean 验证证书颁发机构。 |
{- "Cert": "string",
- "CertKey": "string",
- "CertCa": "string",
- "Verify": true,
- "Password": "string"
}| CargoKey required | string 规范 Cargo 键,格式为 | ||||
required | 数组元素类型 objects (CargoReplicaTask) 分配给此节点的具体持久化副本,按序号排序。 | ||||
Array
| |||||
{- "CargoKey": "string",
- "Replicas": [
- {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "Ordinal": 0
}
]
}| ApiVersion required | string 使用的 API 版本或远程 URL。 | ||||||||||||||||||||||||
数组元素类型 objects or null (StatefileArg) 传给 Statefile 的参数。 | |||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||
数组元素类型 objects or null (CargoSpec) 要创建并运行的 Cargo 列表。 | |||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||
| Group | string or null 设置定义对象的组,默认为 | ||||||||||||||||||||||||
数组元素类型 objects or null (JobPartial) 要创建并运行的任务列表。 | |||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||
null or StatefileMetadata (object) | |||||||||||||||||||||||||
One of null | |||||||||||||||||||||||||
| Namespace | string or null Cargo 和虚拟机部署所在的命名空间。 | ||||||||||||||||||||||||
数组元素类型 objects or null (ResourcePartial) 要创建的资源列表。 | |||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||
数组元素类型 objects or null (SecretPartial) 要创建的 Secret 列表。 | |||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||
数组元素类型 strings or SubStateDef (object) or null (SubState) 包含在当前状态之前应用的子状态。 | |||||||||||||||||||||||||
Array One of string | |||||||||||||||||||||||||
数组元素类型 objects or null (VmSpecPartial) 要创建并运行的虚拟机列表。 | |||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||
{- "ApiVersion": "string",
- "Metadata": { },
- "Args": [
- {
- "Name": "string",
- "Kind": "String",
- "Default": { },
- "Required": true,
- "Multiple": true,
- "Description": "string",
- "Example": "string"
}
], - "SubStates": [
- "string"
], - "Group": "string",
- "Namespace": "string",
- "Secrets": [
- {
- "Name": "string",
- "Kind": "string",
- "Immutable": true,
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Data": {
- "property1": "string",
- "property2": "string"
}
}
], - "Resources": [
- {
- "Name": "string",
- "Kind": "string",
- "Data": {
- "property1": "string",
- "property2": "string"
}, - "Metadata": {
- "property1": "string",
- "property2": "string"
}
}
], - "Cargoes": [
- {
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Replicas": 1,
- "NetworkMode": { },
- "PortBindings": { },
- "Hostname": "string",
- "Dns": [
- "string"
], - "Secrets": [
- "string"
], - "Placement": { },
- "ResourceRequirement": { },
- "InitContainers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
], - "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { },
- "Name": "string",
- "Essential": true,
- "Secrets": [ ],
- "ImagePullSecret": { },
- "ImagePullPolicy": "Never"
}
]
}
], - "VirtualMachines": [
- {
- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "User": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": { }
}
], - "Jobs": [
- {
- "Name": "string",
- "Secrets": [
- "string"
], - "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Schedule": "string",
- "Ttl": 0,
- "ImagePullSecret": "string",
- "ImagePullPolicy": { },
- "Containers": [
- {
- "Hostname": "string",
- "Domainname": "string",
- "User": "string",
- "AttachStdin": true,
- "AttachStdout": true,
- "AttachStderr": true,
- "ExposedPorts": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "Tty": true,
- "OpenStdin": true,
- "StdinOnce": true,
- "Env": [
- "string"
], - "Cmd": [
- "string"
], - "Healthcheck": { },
- "ArgsEscaped": true,
- "Image": "string",
- "Volumes": {
- "property1": {
- "property1": null,
- "property2": null
}, - "property2": {
- "property1": null,
- "property2": null
}
}, - "WorkingDir": "string",
- "Entrypoint": [
- "string"
], - "NetworkDisabled": true,
- "MacAddress": "string",
- "OnBuild": [
- "string"
], - "Labels": {
- "property1": "string",
- "property2": "string"
}, - "StopSignal": "string",
- "StopTimeout": 0,
- "Shell": [
- "string"
], - "HostConfig": { },
- "NetworkingConfig": { }
}
]
}
]
}null or (StatefileArgsValue (StatefileArgsValue (number) or StatefileArgsValue (string) or StatefileArgsValue (boolean) or 数组元素类型 StatefileArgsValue (numbers) or 数组元素类型 StatefileArgsValue (strings))) | |
One of null | |
| Description | string or null 参数简短说明。 |
| Example | string or null 参数示例值。 |
| Kind required | string (StatefileArgKind) 枚举值: "String" "Number" "Boolean" 构建参数类型。 |
| Multiple | boolean 参数接受多个值。 |
| Name required | string 构建参数名称。 |
| Required | boolean 必填参数。 |
{- "Name": "string",
- "Kind": "String",
- "Default": { },
- "Required": true,
- "Multiple": true,
- "Description": "string",
- "Example": "string"
}传给 Statefile 的参数定义。
"String"| About | string or null Statefile 的介绍,显示在名称部分下面。 |
| LongAbout | string or null Statefile 的详细介绍,显示在说明部分下面。 |
| ManContent | string or null 覆盖此 Statefile 的手册页内容。 |
| Name | string or null Statefile 文档的可选标题。 |
| Tags | 数组元素类型 strings or null 与 Statefile 关联的可选标签。 |
{- "Name": "string",
- "About": "string",
- "LongAbout": "string",
- "Tags": [
- "string"
], - "ManContent": "string"
}required | object (BlkioStats) 容器 I/O 统计。 | ||||||||||||||||||||
| |||||||||||||||||||||
required | object (CPUStats) 容器通用 CPU 统计。 | ||||||||||||||||||||
| |||||||||||||||||||||
| id | string | ||||||||||||||||||||
required | object (MemoryStats) 容器通用内存统计。 | ||||||||||||||||||||
| |||||||||||||||||||||
| name | string | ||||||||||||||||||||
null or NetworkStats (object) | |||||||||||||||||||||
One of null | |||||||||||||||||||||
object or null | |||||||||||||||||||||
| |||||||||||||||||||||
| num_procs required | integer <int32> >= 0 | ||||||||||||||||||||
required | object (PidsStats) 容器进程 ID 统计。 | ||||||||||||||||||||
| |||||||||||||||||||||
required | object (CPUStats) 容器通用 CPU 统计。 | ||||||||||||||||||||
| |||||||||||||||||||||
| preread required | string | ||||||||||||||||||||
| read required | string | ||||||||||||||||||||
required | object (StorageStats) 容器文件 I/O 统计。 | ||||||||||||||||||||
| |||||||||||||||||||||
{- "read": "string",
- "preread": "string",
- "num_procs": 0,
- "pids_stats": {
- "current": 0,
- "limit": 0
}, - "network": { },
- "networks": {
- "property1": {
- "rx_dropped": 0,
- "rx_bytes": 0,
- "rx_errors": 0,
- "tx_packets": 0,
- "tx_dropped": 0,
- "rx_packets": 0,
- "tx_errors": 0,
- "tx_bytes": 0
}, - "property2": {
- "rx_dropped": 0,
- "rx_bytes": 0,
- "rx_errors": 0,
- "tx_packets": 0,
- "tx_dropped": 0,
- "rx_packets": 0,
- "tx_errors": 0,
- "tx_bytes": 0
}
}, - "memory_stats": {
- "stats": { },
- "max_usage": 0,
- "usage": 0,
- "failcnt": 0,
- "limit": 0,
- "commit": 0,
- "commit_peak": 0,
- "commitbytes": 0,
- "commitpeakbytes": 0,
- "privateworkingset": 0
}, - "blkio_stats": {
- "io_service_bytes_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_serviced_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_queue_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_service_time_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_wait_time_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_merged_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "io_time_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
], - "sectors_recursive": [
- {
- "major": 0,
- "minor": 0,
- "op": "string",
- "value": 0
}
]
}, - "cpu_stats": {
- "cpu_usage": {
- "percpu_usage": [
- 0
], - "usage_in_usermode": 0,
- "total_usage": 0,
- "usage_in_kernelmode": 0
}, - "system_cpu_usage": 0,
- "online_cpus": 0,
- "throttling_data": {
- "periods": 0,
- "throttled_periods": 0,
- "throttled_time": 0
}
}, - "precpu_stats": {
- "cpu_usage": {
- "percpu_usage": [
- 0
], - "usage_in_usermode": 0,
- "total_usage": 0,
- "usage_in_kernelmode": 0
}, - "system_cpu_usage": 0,
- "online_cpus": 0,
- "throttling_data": {
- "periods": 0,
- "throttled_periods": 0,
- "throttled_time": 0
}
}, - "storage_stats": {
- "read_count_normalized": 0,
- "read_size_bytes": 0,
- "write_count_normalized": 0,
- "write_size_bytes": 0
}, - "name": "string",
- "id": "string"
}| read_count_normalized | integer or null <int64> >= 0 |
| read_size_bytes | integer or null <int64> >= 0 |
| write_count_normalized | integer or null <int64> >= 0 |
| write_size_bytes | integer or null <int64> >= 0 |
{- "read_count_normalized": 0,
- "read_size_bytes": 0,
- "write_count_normalized": 0,
- "write_size_bytes": 0
}| DisableLogging | boolean or null 禁用此目标的日志。 |
| Key required | string 目标 Cargo 或 VM 的键。 |
| Path | string or null 使用 HTTP 时的目标路径。 |
| Port required | integer <int32> >= 0 目标 Cargo 或 VM 的端口。 |
null or (ProxySsl (ProxySslConfig (object) or ProxySsl (string))) | |
One of null | |
{- "Key": "string",
- "Port": 0,
- "Path": "string",
- "DisableLogging": true,
- "Ssl": { }
}| Name required | string 参数名称。 |
required | number or string or boolean or 数组元素类型 numbers or 数组元素类型 strings (StatefileArgsValue) |
One of number <double> 参数值。 | |
{- "Name": "string",
- "Value": 0.1
}数组元素类型 objects or null (SubStateArg) | |||||
Array
| |||||
| Path required | string | ||||
{- "Path": "string",
- "Args": [
- {
- "Name": "string",
- "Value": 0.1
}
]
}null or ClusterInfo (object) | |||||
One of null | |||||
| ControlAvailable | boolean or null | ||||
| Error | string or null | ||||
null or LocalNodeState (string) | |||||
One of null | |||||
| Managers | integer or null <int64> Swarm 管理节点总数。 | ||||
| NodeAddr | string or null Swarm 中其他节点访问此节点的 IP 地址。 | ||||
| NodeID | string or null 节点在 Swarm 中的唯一标识。 | ||||
| Nodes | integer or null <int64> Swarm 节点总数。 | ||||
数组元素类型 objects or null (PeerNode) Swarm 中其他管理节点的 ID 和地址列表。 | |||||
Array
| |||||
{- "NodeID": "string",
- "NodeAddr": "string",
- "LocalNodeState": { },
- "ControlAvailable": true,
- "Error": "string",
- "RemoteManagers": [
- {
- "NodeID": "string",
- "Addr": "string"
}
], - "Nodes": 0,
- "Managers": 0,
- "Cluster": { }
}null or SwarmSpecCaConfig (object) | |||
One of null | |||
null or SwarmSpecDispatcher (object) | |||
One of null | |||
null or SwarmSpecEncryptionConfig (object) | |||
One of null | |||
object or null 用户定义的键值元数据。 | |||
| |||
| Name | string or null Swarm 名称。 | ||
null or SwarmSpecOrchestration (object) | |||
One of null | |||
null or SwarmSpecRaft (object) | |||
One of null | |||
null or SwarmSpecTaskDefaults (object) | |||
One of null | |||
{- "Name": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "Orchestration": { },
- "Raft": { },
- "Dispatcher": { },
- "CAConfig": { },
- "EncryptionConfig": { },
- "TaskDefaults": { }
}数组元素类型 objects or null (SwarmSpecCaConfigExternalCas) 将签名请求转发给外部证书颁发机构的配置。 | |||||||||
Array
| |||||||||
| ForceRotate | integer or null <int64> >= 0 用于强制 Swarm 生成新签名 CA 证书和密钥的整数;仅在未指定 | ||||||||
| NodeCertExpiry | integer or null <int64> 节点证书的签发有效期。 | ||||||||
| SigningCACert | string or null 为全部 Swarm 节点 TLS 叶证书签名的目标 CA 证书,PEM 格式。 | ||||||||
| SigningCAKey | string or null 为全部 Swarm 节点 TLS 叶证书签名的目标 CA 私钥,PEM 格式。 | ||||||||
{- "NodeCertExpiry": 0,
- "ExternalCAs": [
- {
- "Protocol": { },
- "URL": "string",
- "Options": {
- "property1": "string",
- "property2": "string"
}, - "CACert": "string"
}
], - "SigningCACert": "string",
- "SigningCAKey": "string",
- "ForceRotate": 0
}| CACert | string or null 外部 CA 签发 TLS 证书使用的根 CA 证书,PEM 格式。未提供时假定使用当前 Swarm 根 CA 证书。 | ||
object or null 包含键值对的对象,作为外部 CA 驱动的协议专属选项解释。 | |||
| |||
null or SwarmSpecCaConfigExternalCasProtocolEnum (string) | |||
One of null | |||
| URL | string or null 证书签名请求发送的 URL。 | ||
{- "Protocol": { },
- "URL": "string",
- "Options": {
- "property1": "string",
- "property2": "string"
}, - "CACert": "string"
}"EMPTY"| AutoLockManagers | boolean or null 设置后生成密钥,用于锁定管理节点保存的数据。 |
{- "AutoLockManagers": true
}| TaskHistoryRetentionLimit | integer or null <int64> 每个实例或节点保留的历史任务数。负数表示永不删除完成或失败的任务。 |
{- "TaskHistoryRetentionLimit": 0
}| ElectionTick | integer or null <int64> 跟随节点等待领导节点消息的 tick 数,超过后成为候选并启动选举。 |
| HeartbeatTick | integer or null <int64> 心跳之间的 tick 数。每经过 HeartbeatTick 个 tick,领导节点向跟随节点发送心跳。目前 tick 默认为一秒,所以当前可直接对应秒数,但不保证始终如此。 |
| KeepOldSnapshots | integer or null <int64> >= 0 除当前快照之外要保留的快照数量。 |
| LogEntriesForSlowFollowers | integer or null <int64> >= 0 创建快照后,为同步落后的跟随节点保留的日志条目数。 |
| SnapshotInterval | integer or null <int64> >= 0 快照之间的日志条目数。 |
{- "SnapshotInterval": 0,
- "KeepOldSnapshots": 0,
- "LogEntriesForSlowFollowers": 0,
- "ElectionTick": 0,
- "HeartbeatTick": 0
}| Name | string or null 新任务默认使用的日志驱动。 | ||
object or null 所选日志驱动的专属选项,以键值对指定。 | |||
| |||
{- "Name": "string",
- "Options": {
- "property1": "string",
- "property2": "string"
}
}| Architecture | string or null 主机硬件架构,由 Go 运行时( | ||||
| BridgeNfIp6tables | boolean or null 表示主机是否提供 | ||||
| BridgeNfIptables | boolean or null 表示主机是否提供 | ||||
| CDISpecDirs | 数组元素类型 strings or null CDI(Container Device Interface)规范所在目录列表。规范定义创建容器时,对 OCI 运行时规格所做的厂商专属修改。列表为空表示禁用 CDI 设备注入。CDI 注入要求守护进程启用实验性功能,非实验性守护进程始终返回空列表。 | ||||
null or SystemInfoCgroupDriverEnum (string) | |||||
One of null | |||||
null or SystemInfoCgroupVersionEnum (string) | |||||
One of null | |||||
null or Commit (object) | |||||
One of null | |||||
| Containers | integer or null <int64> 主机容器总数。 | ||||
| ContainersPaused | integer or null <int64> 状态为 | ||||
| ContainersRunning | integer or null <int64> 状态为 | ||||
| ContainersStopped | integer or null <int64> 状态为 | ||||
| CpuCfsPeriod | boolean or null 表示主机是否支持 CPU CFS(完全公平调度器)周期。 | ||||
| CpuCfsQuota | boolean or null 表示主机是否支持 CPU CFS(完全公平调度器)配额。 | ||||
| CPUSet | boolean or null 表示主机是否支持 CPUset(cpuset.cpus、cpuset.mems)。参见 cpuset(7)。 | ||||
| CPUShares | boolean or null 表示主机是否支持 CPU Shares 限制。 | ||||
| Debug | boolean or null 表示守护进程是否在调试模式运行,或启用了调试级日志。 | ||||
数组元素类型 objects or null (SystemInfoDefaultAddressPools) 本地网络的自定义默认地址池列表,可在 daemon.json 或 dockerd 选项中指定。例如 Base 为 "10.10.0.0/16"、Size 为 24 时,会定义 256 个 10.10.[0-255].0/24 地址池。 | |||||
Array
| |||||
| DefaultRuntime | string or null 启动容器时默认使用的 OCI 运行时名称,可在创建各容器时覆盖。 | ||||
| DockerRootDir | string or null Docker 持久化状态根目录。Linux 默认为 | ||||
| Driver | string or null 正在使用的存储驱动名称。 | ||||
| DriverStatus | 数组元素类型 strings or null[ items ] 存储驱动专属信息,由驱动提供 "label" / "value" 对,格式与命令行 | ||||
| ExperimentalBuild | boolean or null 表示守护进程是否启用实验性功能。 | ||||
null or GenericResourcesInner (object) | |||||
One of null | |||||
| HttpProxy | string or null 守护进程的 HTTP 代理配置,来自 | ||||
| HttpsProxy | string or null 守护进程的 HTTPS 代理配置,来自 | ||||
| ID | string or null 守护进程唯一标识。 | ||||
| Images | integer or null <int64> 主机镜像总数,包括_有标签_和_无标签_(悬空)镜像。 | ||||
| IndexServerAddress | string or null 镜像搜索所用索引服务器的地址或 URL,也作为 Docker Hub 和 Docker Cloud 用户认证的默认服务器。 | ||||
| InitBinary | string or null
| ||||
null or Commit (object) | |||||
One of null | |||||
| IPv4Forwarding | boolean or null 表示是否启用 IPv4 转发。 | ||||
null or SystemInfoIsolationEnum (string) | |||||
One of null | |||||
| KernelMemoryTCP | boolean or null 表示主机是否启用内核 TCP 内存限制,不支持时省略。cgroup v2 不支持内核 TCP 内存限制及对应的 | ||||
| KernelVersion | string or null 主机内核版本。Linux 从 | ||||
| Labels | 数组元素类型 strings or null 守护进程上设置的用户自定义标签(键值元数据)。 /nodes/(id) 端点获取。
| ||||
| LiveRestoreEnabled | boolean or null 表示是否启用 live restore。启用后,守护进程关闭时容器继续运行;守护进程启动并检测到运行中的容器时也保持运行。 | ||||
| LoggingDriver | string or null 新容器默认使用的日志驱动。 | ||||
| MemoryLimit | boolean or null 表示主机是否支持内存限制。 | ||||
| MemTotal | integer or null <int64> 主机可用物理内存总量,单位字节。 | ||||
| Name | string or null 主机的主机名。 | ||||
| NCPU | integer or null <int64> 守护进程可使用的逻辑 CPU 数量,启动时通过操作系统查询。启动后操作系统 CPU 分配变化不会反映在此值中。 | ||||
| NEventsListener | integer or null <int64> 已订阅的事件监听器数量。 | ||||
| NFd | integer or null <int64> 守护进程使用的文件描述符总数,仅在启用调试模式时返回。 | ||||
| NGoroutines | integer or null <int64> 当前 goroutine 数量,仅在启用调试模式时返回。 | ||||
| NoProxy | string or null 不使用代理的域名后缀列表,以逗号分隔。此值来自 | ||||
| OomKillDisable | boolean or null 表示主机是否支持禁用 OOM killer。 | ||||
| OperatingSystem | string or null 主机操作系统名称,如 "Ubuntu 16.04.2 LTS" 或 "Windows Server 2016 Datacenter"。 | ||||
| OSType | string or null 主机操作系统的通用类型,由 Go 运行时( | ||||
| OSVersion | string or null 主机操作系统版本。 | ||||
| PidsLimit | boolean or null 表示主机内核是否支持 PID 限制。 | ||||
null or PluginsInfo (object) | |||||
One of null | |||||
| ProductLicense | string or null 报告守护进程的产品许可证摘要。如果应用了商业许可证,会包含节点数量和到期时间等信息。 | ||||
null or RegistryServiceConfig (object) | |||||
One of null | |||||
null or Commit (object) | |||||
One of null | |||||
object or null 守护进程配置的 OCI 兼容运行时列表,键保存引用运行时的名称。Docker 守护进程依靠经 | |||||
| |||||
| SecurityOptions | 数组元素类型 strings or null 守护进程启用的安全功能列表,如 apparmor、seccomp、SELinux、用户命名空间 userns、rootless 和 no-new-privileges。各功能可能包含额外配置,以逗号分隔的键值对列出。 | ||||
| ServerVersion | string or null 守护进程版本字符串。 | ||||
| SwapLimit | boolean or null 表示主机是否支持交换内存限制。 | ||||
null or SwarmInfo (object) | |||||
One of null | |||||
| SystemTime | string or null 当前系统时间,使用纳秒精度的 RFC 3339 格式。 | ||||
| Warnings | 数组元素类型 strings or null 缺失功能或守护进程配置问题的警告和信息消息列表,客户端可将这些消息展示给用户。 | ||||
{- "ID": "string",
- "Containers": 0,
- "ContainersRunning": 0,
- "ContainersPaused": 0,
- "ContainersStopped": 0,
- "Images": 0,
- "Driver": "string",
- "DriverStatus": [
- [
- "string"
]
], - "DockerRootDir": "string",
- "Plugins": { },
- "MemoryLimit": true,
- "SwapLimit": true,
- "KernelMemoryTCP": true,
- "CpuCfsPeriod": true,
- "CpuCfsQuota": true,
- "CPUShares": true,
- "CPUSet": true,
- "PidsLimit": true,
- "OomKillDisable": true,
- "IPv4Forwarding": true,
- "BridgeNfIptables": true,
- "BridgeNfIp6tables": true,
- "Debug": true,
- "NFd": 0,
- "NGoroutines": 0,
- "SystemTime": "string",
- "LoggingDriver": "string",
- "CgroupDriver": { },
- "CgroupVersion": { },
- "NEventsListener": 0,
- "KernelVersion": "string",
- "OperatingSystem": "string",
- "OSVersion": "string",
- "OSType": "string",
- "Architecture": "string",
- "NCPU": 0,
- "MemTotal": 0,
- "IndexServerAddress": "string",
- "RegistryConfig": { },
- "GenericResources": { },
- "HttpProxy": "string",
- "HttpsProxy": "string",
- "NoProxy": "string",
- "Name": "string",
- "Labels": [
- "string"
], - "ExperimentalBuild": true,
- "ServerVersion": "string",
- "Runtimes": {
- "property1": {
- "path": "string",
- "runtimeArgs": [
- "string"
], - "status": {
- "property1": "string",
- "property2": "string"
}
}, - "property2": {
- "path": "string",
- "runtimeArgs": [
- "string"
], - "status": {
- "property1": "string",
- "property2": "string"
}
}
}, - "DefaultRuntime": "string",
- "Swarm": { },
- "LiveRestoreEnabled": true,
- "Isolation": { },
- "InitBinary": "string",
- "ContainerdCommit": { },
- "RuncCommit": { },
- "InitCommit": { },
- "SecurityOptions": [
- "string"
], - "ProductLicense": "string",
- "DefaultAddressPools": [
- {
- "Base": "string",
- "Size": 0
}
], - "Warnings": [
- "string"
], - "CDISpecDirs": [
- "string"
]
}"EMPTY"| Base | string or null CIDR 格式网络地址。 |
| Size | integer or null <int64> 网络池大小。 |
{- "Base": "string",
- "Size": 0
}"EMPTY"| periods required | integer <int64> >= 0 |
| throttled_periods required | integer <int64> >= 0 |
| throttled_time required | integer <int64> >= 0 |
{- "periods": 0,
- "throttled_periods": 0,
- "throttled_time": 0
}| CertIssuerPublicKey | string or null 颁发者的原始公钥字节,使用 URL 安全 Base64 编码。 |
| CertIssuerSubject | string or null 颁发者的原始 subject 字节,使用 URL 安全 Base64 编码。 |
| TrustRoot | string or null 验证叶 TLS 证书的根 CA 证书。 |
{- "TrustRoot": "string",
- "CertIssuerSubject": "string",
- "CertIssuerPublicKey": "string"
}| DisableLogging | boolean or null 禁用此目标的日志。 |
| Key required | string 目标 Cargo 或 VM 的键。 |
| Path | string or null 使用 HTTP 时的目标路径。 |
| Port required | integer <int32> >= 0 目标 Cargo 或 VM 的端口。 |
null or (ProxySsl (ProxySslConfig (object) or ProxySsl (string))) | |
One of null | |
{- "Key": "string",
- "Port": 0,
- "Path": "string",
- "DisableLogging": true,
- "Ssl": { }
}| CreatedAt required | string <date-time> VM 创建时间。 | ||||||||||||||||||||||||||||||
| NamespaceName required | string 命名空间名称。 | ||||||||||||||||||||||||||||||
required | object (VmSpec) VM 规格。 | ||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||
required | object (ObjPsStatus) VM 状态。 | ||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Version": "string",
- "VmKey": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "User": "string",
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": {
- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}
}
}| Cpu required | integer <int64> >= 0 VM 的 CPU 数量(默认:1)。 |
| Dns | 数组元素类型 strings or null VM 使用的 DNS 服务器列表。 |
| HostTun | boolean or null 使用主机 TUN 设备。 |
| Kvm | boolean or null 启用 KVM 加速(默认:false)。 |
| LinkNetIface | string or null 连接 VM 的网络接口(默认:eth0)。 |
| Memory required | integer <int64> >= 0 VM 内存,单位 MB(默认:512)。 |
| NetIface | string or null 要配置的 VM 网络接口(默认:ens3)。 |
| NetworkMode | string or null VM 运行时使用的容器网络。 |
| Runtime | string or null VM 使用的容器镜像名称(默认:nanocl-qemu)。 |
{- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}| CreatedAt required | string <date-time> VM 创建时间。 | ||||||||||||||||||||||||||||||
| InstanceRunning required | integer >= 0 运行实例数。 | ||||||||||||||||||||||||||||||
required | 数组元素类型 objects (Process) 实例列表。 | ||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||
| InstanceTotal required | integer >= 0 实例数量。 | ||||||||||||||||||||||||||||||
| NamespaceName required | string 命名空间名称。 | ||||||||||||||||||||||||||||||
required | object (VmSpec) VM 规格。 | ||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||
required | object (ObjPsStatus) VM 状态。 | ||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||
{- "NamespaceName": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Version": "string",
- "VmKey": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "User": "string",
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": {
- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}
}, - "Instances": [
- {
- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Kind": "vm",
- "NodeName": "string",
- "KindKey": "string",
- "IpAddress": "string",
- "Data": {
- "Id": "string",
- "Created": "string",
- "Path": "string",
- "Args": [
- "string"
], - "State": { },
- "Image": "string",
- "ResolvConfPath": "string",
- "HostnamePath": "string",
- "HostsPath": "string",
- "LogPath": "string",
- "Name": "string",
- "RestartCount": 0,
- "Driver": "string",
- "Platform": "string",
- "MountLabel": "string",
- "ProcessLabel": "string",
- "AppArmorProfile": "string",
- "ExecIDs": [
- "string"
], - "HostConfig": { },
- "GraphDriver": { },
- "SizeRw": 0,
- "SizeRootFs": 0,
- "Mounts": [
- {
- "Type": { },
- "Name": "string",
- "Source": "string",
- "Destination": "string",
- "Driver": "string",
- "Mode": "string",
- "RW": true,
- "Propagation": "string"
}
], - "Config": { },
- "NetworkSettings": { }
}
}
]
}| CreatedAt required | string <date-time> VM 规格创建时间。 | ||||||||||||||||||
required | object (VmHostConfig) VM 的资源(CPU、内存、网络)。 | ||||||||||||||||||
| |||||||||||||||||||
| Hostname | string or null VM 主机名。 | ||||||||||||||||||
| Image required | string VM 使用的镜像,必须提供完整路径,如 /var/lib/nanocl/vm/image.qcow2。 | ||||||||||||||||||
null or Config (object) | |||||||||||||||||||
One of null | |||||||||||||||||||
| Key required | string <uuid> VM 规格唯一标识。 | ||||||||||||||||||
object or null 用户定义的键值元数据。 | |||||||||||||||||||
| |||||||||||||||||||
| MacAddress | string or null VM 的 MAC 地址。 | ||||||||||||||||||
object 用户定义的元数据。 | |||||||||||||||||||
| |||||||||||||||||||
| Name required | string VM 名称。 | ||||||||||||||||||
| Password | string or null VM 默认密码(cloud)。 | ||||||||||||||||||
| SshKey | string or null 用户默认 SSH 密钥。 | ||||||||||||||||||
| User | string or null VM 默认用户(cloud)。 | ||||||||||||||||||
| Version required | string 规格版本。 | ||||||||||||||||||
| VmKey required | string 规范 VM 键,格式为 | ||||||||||||||||||
{- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Version": "string",
- "VmKey": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "User": "string",
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": {
- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}
}null or VmHostConfig (object) | |||
One of null | |||
| Hostname | string or null VM 主机名(默认:根据名称生成)。 | ||
| Image required | string VM 使用的镜像,必须提供完整路径,如 /var/lib/nanocl/vm/image.qcow2。 | ||
null or Config (object) | |||
One of null | |||
object or null 用户定义的键值元数据。 | |||
| |||
| MacAddress | string or null VM 的 MAC 地址(默认自动生成)。 | ||
object 用户定义的元数据。 | |||
| |||
| Name required | string VM 名称。 | ||
| Password | string or null VM 默认密码(默认:cloud)。 | ||
| SshKey | string or null 用户默认 SSH 公钥(推荐)。 | ||
| User | string or null VM 默认用户(默认:cloud)。 | ||
{- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "User": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": { }
}null or VmHostConfig (object) | |||
One of null | |||
| Hostname | string or null VM 主机名。 | ||
null or Config (object) | |||
One of null | |||
object or null 用户定义的键值元数据。 | |||
| |||
object 用户定义的元数据。 | |||
| |||
| Name | string or null VM 名称。 | ||
| Password | string or null VM 默认密码(cloud)。 | ||
| SshKey | string or null 用户默认 SSH 密钥。 | ||
| User | string or null VM 默认用户(cloud)。 | ||
{- "Name": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "User": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": { }
}| CreatedAt required | string <date-time> VM 创建时间。 | ||||||||||||||||||||||||||||||
| InstanceRunning required | integer >= 0 运行实例数。 | ||||||||||||||||||||||||||||||
| InstanceTotal required | integer >= 0 实例数量。 | ||||||||||||||||||||||||||||||
| NamespaceName required | string 命名空间名称。 | ||||||||||||||||||||||||||||||
required | object (VmSpec) VM 规格。 | ||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||
required | object (ObjPsStatus) VM 状态。 | ||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||
{- "NamespaceName": "string",
- "Status": {
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Wanted": "create",
- "PrevWanted": "create",
- "Actual": "create",
- "PrevActual": "create",
- "Health": "healthy"
}, - "CreatedAt": "2019-08-24T14:15:22Z",
- "InstanceTotal": 0,
- "InstanceRunning": 0,
- "Spec": {
- "Key": "5eb041b0-19c9-4022-bd51-0e723885f5dd",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "Version": "string",
- "VmKey": "string",
- "Metadata": {
- "property1": "string",
- "property2": "string"
}, - "Hostname": "string",
- "Password": "string",
- "SshKey": "string",
- "InitContainer": { },
- "User": "string",
- "Image": "string",
- "MacAddress": "string",
- "Labels": {
- "property1": "string",
- "property2": "string"
}, - "HostConfig": {
- "Cpu": 0,
- "Memory": 0,
- "NetIface": "string",
- "LinkNetIface": "string",
- "Kvm": true,
- "Dns": [
- "string"
], - "Runtime": "string",
- "NetworkMode": "string",
- "HostTun": true
}
}
}| CreatedAt required | string <date-time> 网络首次记录时间。 | ||||||||||||||||||||||||||
required | object (Network) 完整的 Docker 网络检查响应。 | ||||||||||||||||||||||||||
| |||||||||||||||||||||||||||
| Key required | string 稳定键,格式为 | ||||||||||||||||||||||||||
| Metadata | any 刷新快照时保留的用户自定义元数据。 | ||||||||||||||||||||||||||
| Name required | string Docker 网络名称。 | ||||||||||||||||||||||||||
| NodeName required | string Docker 守护进程拥有此网络的节点。 | ||||||||||||||||||||||||||
| UpdatedAt required | string <date-time> Docker 检查快照最近刷新时间。 | ||||||||||||||||||||||||||
{- "Key": "string",
- "CreatedAt": "2019-08-24T14:15:22Z",
- "UpdatedAt": "2019-08-24T14:15:22Z",
- "Name": "string",
- "NodeName": "string",
- "Data": {
- "Name": "string",
- "Id": "string",
- "Created": { },
- "Scope": "string",
- "Driver": "string",
- "EnableIPv6": true,
- "IPAM": { },
- "Internal": true,
- "Attachable": true,
- "Ingress": true,
- "Containers": {
- "property1": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}, - "property2": {
- "Name": "string",
- "EndpointID": "string",
- "MacAddress": "string",
- "IPv4Address": "string",
- "IPv6Address": "string"
}
}, - "Options": {
- "property1": "string",
- "property2": "string"
}, - "Labels": {
- "property1": "string",
- "property2": "string"
}
}, - "Metadata": null
}