你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

Containers interface

表示容器的接口。

方法

attach(string, string, string, ContainersAttachOptionalParams)

附加到指定资源组和容器组中特定容器实例的输出流。

executeCommand(string, string, string, ContainerExecRequest, ContainersExecuteCommandOptionalParams)

为指定资源组和容器组中的特定容器实例执行命令。

listLogs(string, string, string, ContainersListLogsOptionalParams)

获取指定资源组和容器组中指定容器实例的日志。

方法详细信息

attach(string, string, string, ContainersAttachOptionalParams)

附加到指定资源组和容器组中特定容器实例的输出流。

function attach(resourceGroupName: string, containerGroupName: string, containerName: string, options?: ContainersAttachOptionalParams): Promise<ContainerAttachResponse>

参数

resourceGroupName

string

资源组的名称。

containerGroupName

string

容器组的名称。

containerName

string

容器实例的名称。

options
ContainersAttachOptionalParams

选项参数。

返回

executeCommand(string, string, string, ContainerExecRequest, ContainersExecuteCommandOptionalParams)

为指定资源组和容器组中的特定容器实例执行命令。

function executeCommand(resourceGroupName: string, containerGroupName: string, containerName: string, containerExecRequest: ContainerExecRequest, options?: ContainersExecuteCommandOptionalParams): Promise<ContainerExecResponse>

参数

resourceGroupName

string

资源组的名称。

containerGroupName

string

容器组的名称。

containerName

string

容器实例的名称。

containerExecRequest
ContainerExecRequest

exec 命令的请求。

options
ContainersExecuteCommandOptionalParams

选项参数。

返回

listLogs(string, string, string, ContainersListLogsOptionalParams)

获取指定资源组和容器组中指定容器实例的日志。

function listLogs(resourceGroupName: string, containerGroupName: string, containerName: string, options?: ContainersListLogsOptionalParams): Promise<Logs>

参数

resourceGroupName

string

资源组的名称。

containerGroupName

string

容器组的名称。

containerName

string

容器实例的名称。

options
ContainersListLogsOptionalParams

选项参数。

返回

Promise<Logs>