az containerapp env
Note
此命令组具有在 Azure CLI 和至少一个扩展中定义的命令。 安装每个扩展,使其受益于其扩展功能。 了解更多关于扩展的信息。
用于管理容器应用环境的命令。
命令
az containerapp env create
创建容器应用环境。
az containerapp env create --name
--resource-group
[--certificate-file --custom-domain-certificate-file]
[--certificate-password --custom-domain-certificate-password]
[--custom-domain-dns-suffix --dns-suffix]
[--dapr-connection-string]
[--enable-mtls {false, true}]
[--enable-peer-to-peer-encryption {false, true}]
[--enable-workload-profiles {false, true}]
[--infrastructure-subnet-resource-id]
[--internal-only {false, true}]
[--location]
[--logs-destination {azure-monitor, log-analytics, none}]
[--logs-workspace-id]
[--logs-workspace-key]
[--no-wait]
[--platform-reserved-cidr]
[--platform-reserved-dns-ip]
[--storage-account]
[--tags]
[--zone-redundant]
示例
使用自动生成的 Log Analytics 工作区创建环境。
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--location eastus2
创建区域冗余环境
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--location eastus2 --zone-redundant
使用现有的 Log Analytics 工作区创建环境。
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--logs-workspace-id myLogsWorkspaceID \
--logs-workspace-key myLogsWorkspaceKey \
--location eastus2
创建启用了工作负荷配置文件的环境。
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--location eastus2 --enable-workload-profiles
在没有启用工作负荷配置文件的情况下创建环境。
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--location eastus2 --enable-workload-profiles false
必需参数
容器应用环境的名称。
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
环境自定义域的证书文件 (.pfx 或 .pem)的文件路径。 若要管理容器应用的证书,请使用 az containerapp env certificate。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境的自定义域的证书文件密码。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境的自定义域的 DNS 后缀。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
Dapr 用于将服务导出到服务通信遥测的 Application Insights 连接字符串。
| 属性 | 值 |
|---|---|
| Parameter group: | Dapr Arguments |
指示是否为环境启用了 mTLS 对等身份验证的布尔值。
| 属性 | 值 |
|---|---|
| Parameter group: | Peer Authentication Arguments |
| 接受的值: | false, true |
指示是否为环境启用对等流量加密的布尔值。
| 属性 | 值 |
|---|---|
| Parameter group: | Peer Traffic Configuration Arguments |
| 接受的值: | false, true |
指示环境是否启用了工作负荷配置文件的布尔值。
| 属性 | 值 |
|---|---|
| 默认值: | True |
| 接受的值: | false, true |
基础结构组件和用户应用容器的子网的资源 ID。
| 属性 | 值 |
|---|---|
| Parameter group: | Virtual Network Arguments |
指示环境只有内部负载均衡器的布尔值。 这些环境没有公共静态 IP 资源,因此,如果启用此属性,则必须提供 infrastructureSubnetResourceId。
| 属性 | 值 |
|---|---|
| Parameter group: | Virtual Network Arguments |
| 默认值: | False |
| 接受的值: | false, true |
资源的位置。 示例:eastus2、northeurope。
日志目标。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
| 默认值: | log-analytics |
| 接受的值: | azure-monitor, log-analytics, none |
要向其发送诊断日志的 Log Analytics 工作区的工作区 ID。 仅适用于日志目标“log-analytics”。 可以使用“az monitor log-analytics workspace create”创建一个。 可能会应用额外的计费。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
用于配置 Log Analytics 工作区的 Log Analytics 工作区密钥。 仅适用于日志目标“log-analytics”。 可以使用“az monitor log-analytics workspace get-shared-keys”检索密钥。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
不等待长时间运行的操作完成。
| 属性 | 值 |
|---|---|
| 默认值: | False |
CIDR 表示法中的 IP 范围,可为环境基础结构 IP 地址保留。 它不得与任何其他子网 IP 范围重叠。
| 属性 | 值 |
|---|---|
| Parameter group: | Virtual Network Arguments |
平台保留 CIDR 定义的 IP 地址,将为内部 DNS 服务器保留。
| 属性 | 值 |
|---|---|
| Parameter group: | Virtual Network Arguments |
用于 Azure Monitor 的存储帐户的名称或资源 ID。 如果提供此值,将自动创建 Azure Monitor 诊断设置。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
空格分隔标记:key[=value] [key[=value] ...]。使用“”清除现有标记。
在环境中启用区域冗余。 不能在没有 --infrastructure-subnet-resource-id 的情况下使用。如果与 --location 一起使用,则子网的位置必须匹配。
| 属性 | 值 |
|---|---|
| 默认值: | False |
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env create (containerapp 扩展)
创建容器应用环境。
az containerapp env create --name
--resource-group
[--certificate-akv-url --custom-domain-certificate-akv-url]
[--certificate-file --custom-domain-certificate-file]
[--certificate-identity --custom-domain-certificate-identity]
[--certificate-password --custom-domain-certificate-password]
[--custom-domain-dns-suffix --dns-suffix]
[--dapr-connection-string]
[--enable-dedicated-gpu {false, true}]
[--enable-mtls {false, true}]
[--enable-peer-to-peer-encryption {false, true}]
[--enable-workload-profiles {false, true}]
[--infrastructure-resource-group]
[--infrastructure-subnet-resource-id]
[--internal-only {false, true}]
[--location]
[--logs-destination {azure-monitor, log-analytics, none}]
[--logs-dynamic-json-columns {false, true}]
[--logs-workspace-id]
[--logs-workspace-key]
[--mi-system-assigned]
[--mi-user-assigned]
[--no-wait]
[--platform-reserved-cidr]
[--platform-reserved-dns-ip]
[--public-network-access {Disabled, Enabled}]
[--storage-account]
[--tags]
[--zone-redundant]
示例
使用自动生成的 Log Analytics 工作区创建环境。
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--location eastus2
创建区域冗余环境
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--location eastus2 --zone-redundant
使用现有的 Log Analytics 工作区创建环境。
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--logs-workspace-id myLogsWorkspaceID \
--logs-workspace-key myLogsWorkspaceKey \
--location eastus2
创建启用了工作负荷配置文件的环境。
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--location eastus2 --enable-workload-profiles
在没有启用工作负荷配置文件的情况下创建环境。
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--location eastus2 --enable-workload-profiles false
创建具有系统分配标识和用户分配标识的环境。
az containerapp env create -n MyContainerappEnvironment -g MyResourceGroup \
--location eastus2 --mi-system-assigned --mi-user-assigned MyUserIdentityResourceId
必需参数
容器应用环境的名称。
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
指向保存证书的 Azure Key Vault 机密的 URL。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境自定义域的证书文件 (.pfx 或 .pem)的文件路径。 若要管理容器应用的证书,请使用 az containerapp env certificate。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
使用 Azure Key Vault 进行身份验证的托管标识的资源 ID,或使用系统分配的标识。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境的自定义域的证书文件密码。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境的自定义域的 DNS 后缀。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
Dapr 用于将服务导出到服务通信遥测的 Application Insights 连接字符串。
| 属性 | 值 |
|---|---|
| Parameter group: | Dapr Arguments |
指示环境是否启用了专用 gpu 的布尔值。
| 属性 | 值 |
|---|---|
| 默认值: | False |
| 接受的值: | false, true |
指示是否为环境启用了 mTLS 对等身份验证的布尔值。
| 属性 | 值 |
|---|---|
| Parameter group: | Peer Authentication Arguments |
| 接受的值: | false, true |
指示是否为环境启用对等流量加密的布尔值。
| 属性 | 值 |
|---|---|
| Parameter group: | Peer Traffic Configuration Arguments |
| 接受的值: | false, true |
指示环境是否启用了工作负荷配置文件的布尔值。
| 属性 | 值 |
|---|---|
| 默认值: | True |
| 接受的值: | false, true |
将包含基础结构资源的资源组的名称。 如果未提供,将生成资源组名称。
| 属性 | 值 |
|---|---|
| Parameter group: | Virtual Network Arguments |
基础结构组件和用户应用容器的子网的资源 ID。
| 属性 | 值 |
|---|---|
| Parameter group: | Virtual Network Arguments |
指示环境只有内部负载均衡器的布尔值。 这些环境没有公共静态 IP 资源,因此,如果启用此属性,则必须提供 infrastructureSubnetResourceId。
| 属性 | 值 |
|---|---|
| Parameter group: | Virtual Network Arguments |
| 默认值: | False |
| 接受的值: | false, true |
资源的位置。 示例:eastus2、northeurope。
日志目标。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
| 默认值: | log-analytics |
| 接受的值: | azure-monitor, log-analytics, none |
指示是否分析 json 字符串日志到动态 json 列的布尔值。 仅适用于目标 log-analytics。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
| 默认值: | False |
| 接受的值: | false, true |
要向其发送诊断日志的 Log Analytics 工作区的工作区 ID。 仅适用于日志目标“log-analytics”。 可以使用“az monitor log-analytics workspace create”创建一个。 可能会应用额外的计费。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
用于配置 Log Analytics 工作区的 Log Analytics 工作区密钥。 仅适用于日志目标“log-analytics”。 可以使用“az monitor log-analytics workspace get-shared-keys”检索密钥。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
指示是否分配系统分配标识的布尔值。
| 属性 | 值 |
|---|---|
| Parameter group: | Identity Arguments |
| 默认值: | False |
要分配的空间分隔用户标识。
| 属性 | 值 |
|---|---|
| Parameter group: | Identity Arguments |
不等待长时间运行的操作完成。
| 属性 | 值 |
|---|---|
| 默认值: | False |
CIDR 表示法中的 IP 范围,可为环境基础结构 IP 地址保留。 它不得与任何其他子网 IP 范围重叠。
| 属性 | 值 |
|---|---|
| Parameter group: | Virtual Network Arguments |
平台保留 CIDR 定义的 IP 地址,将为内部 DNS 服务器保留。
| 属性 | 值 |
|---|---|
| Parameter group: | Virtual Network Arguments |
允许或阻止所有公共流量。
| 属性 | 值 |
|---|---|
| 接受的值: | Disabled, Enabled |
用于 Azure Monitor 的存储帐户的名称或资源 ID。 如果提供此值,将自动创建 Azure Monitor 诊断设置。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
空格分隔标记:key[=value] [key[=value] ...]。使用“”清除现有标记。
在环境中启用区域冗余。 不能在没有 --infrastructure-subnet-resource-id 的情况下使用。如果与 --location 一起使用,则子网的位置必须匹配。
| 属性 | 值 |
|---|---|
| 默认值: | False |
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env delete
删除容器应用环境。
az containerapp env delete [--ids]
[--name]
[--no-wait]
[--resource-group]
[--subscription]
[--yes]
示例
删除环境。
az containerapp env delete -n MyContainerappEnvironment -g MyResourceGroup
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
容器应用环境的名称。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
不等待长时间运行的操作完成。
| 属性 | 值 |
|---|---|
| 默认值: | False |
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
不要提示确认。
| 属性 | 值 |
|---|---|
| 默认值: | False |
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env delete (containerapp 扩展)
删除容器应用环境。
az containerapp env delete [--ids]
[--name]
[--no-wait]
[--resource-group]
[--subscription]
[--yes]
示例
删除环境。
az containerapp env delete -n MyContainerappEnvironment -g MyResourceGroup
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
容器应用环境的名称。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
不等待长时间运行的操作完成。
| 属性 | 值 |
|---|---|
| 默认值: | False |
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
不要提示确认。
| 属性 | 值 |
|---|---|
| 默认值: | False |
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env list
按订阅或资源组列出容器应用环境。
az containerapp env list [--resource-group]
示例
列出当前订阅中的环境。
az containerapp env list
按资源组列出环境。
az containerapp env list -g MyResourceGroup
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env list (containerapp 扩展)
按订阅或资源组列出容器应用环境。
az containerapp env list [--resource-group]
示例
列出当前订阅中的环境。
az containerapp env list
按资源组列出环境。
az containerapp env list -g MyResourceGroup
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env list-usages
列出特定托管环境的配额使用情况。
az containerapp env list-usages [--ids]
[--name]
[--resource-group]
[--subscription]
示例
列出特定托管环境的配额使用情况。
az containerapp env list-usages -n MyEnv -g MyResourceGroup
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
容器应用环境的名称。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env show
显示容器应用环境的详细信息。
az containerapp env show [--ids]
[--name]
[--resource-group]
[--subscription]
示例
显示环境的详细信息。
az containerapp env show -n MyContainerappEnvironment -g MyResourceGroup
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
容器应用环境的名称。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env show (containerapp 扩展)
显示容器应用环境的详细信息。
az containerapp env show [--ids]
[--name]
[--resource-group]
[--subscription]
示例
显示环境的详细信息。
az containerapp env show -n MyContainerappEnvironment -g MyResourceGroup
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
容器应用环境的名称。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env update
更新容器应用环境。
az containerapp env update [--certificate-file --custom-domain-certificate-file]
[--certificate-password --custom-domain-certificate-password]
[--custom-domain-dns-suffix --dns-suffix]
[--dapr-connection-string]
[--enable-mtls {false, true}]
[--enable-peer-to-peer-encryption {false, true}]
[--ids]
[--logs-destination {azure-monitor, log-analytics, none}]
[--logs-workspace-id]
[--logs-workspace-key]
[--max-nodes]
[--min-nodes]
[--name]
[--no-wait]
[--resource-group]
[--storage-account]
[--subscription]
[--tags]
[--workload-profile-name]
[--workload-profile-type]
示例
更新环境的自定义域配置。
az containerapp env update -n MyContainerappEnvironment -g MyResourceGroup \
--dns-suffix my-suffix.net --certificate-file MyFilePath \
--certificate-password MyCertPass
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
环境自定义域的证书文件 (.pfx 或 .pem)的文件路径。 若要管理容器应用的证书,请使用 az containerapp env certificate。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境的自定义域的证书文件密码。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境的自定义域的 DNS 后缀。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
Dapr 用于将服务导出到服务通信遥测的 Application Insights 连接字符串。 使用“none”将其删除。
| 属性 | 值 |
|---|---|
| Parameter group: | Dapr Arguments |
指示是否为环境启用了 mTLS 对等身份验证的布尔值。
| 属性 | 值 |
|---|---|
| Parameter group: | Peer Authentication Arguments |
| 接受的值: | false, true |
指示是否为环境启用对等流量加密的布尔值。
| 属性 | 值 |
|---|---|
| Parameter group: | Peer Traffic Configuration Arguments |
| 接受的值: | false, true |
一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
日志目标。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
| 接受的值: | azure-monitor, log-analytics, none |
要向其发送诊断日志的 Log Analytics 工作区的工作区 ID。 仅适用于日志目标“log-analytics”。 可以使用“az monitor log-analytics workspace create”创建一个。 可能会应用额外的计费。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
用于配置 Log Analytics 工作区的 Log Analytics 工作区密钥。 仅适用于日志目标“log-analytics”。 可以使用“az monitor log-analytics workspace get-shared-keys”检索密钥。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
此工作负荷配置文件所需的最大节点 --workload-profile-name。
此工作负荷配置文件所需的最小节点 --workload-profile-name。
容器应用环境的名称。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
不等待长时间运行的操作完成。
| 属性 | 值 |
|---|---|
| 默认值: | False |
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
用于 Azure Monitor 的存储帐户的名称或资源 ID。 如果提供此值,将自动创建 Azure Monitor 诊断设置。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
空格分隔标记:key[=value] [key[=value] ...]。使用“”清除现有标记。
工作负荷配置文件的友好名称。
在此环境中添加或更新的工作负荷配置文件的类型,需要 --workload-profile-name。
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
az containerapp env update (containerapp 扩展)
更新容器应用环境。
az containerapp env update [--certificate-akv-url --custom-domain-certificate-akv-url]
[--certificate-file --custom-domain-certificate-file]
[--certificate-identity --custom-domain-certificate-identity]
[--certificate-password --custom-domain-certificate-password]
[--custom-domain-dns-suffix --dns-suffix]
[--enable-mtls {false, true}]
[--enable-peer-to-peer-encryption {false, true}]
[--ids]
[--logs-destination {azure-monitor, log-analytics, none}]
[--logs-dynamic-json-columns {false, true}]
[--logs-workspace-id]
[--logs-workspace-key]
[--max-nodes]
[--min-nodes]
[--name]
[--no-wait]
[--public-network-access {Disabled, Enabled}]
[--resource-group]
[--storage-account]
[--subscription]
[--tags]
[--workload-profile-name]
[--workload-profile-type]
示例
更新环境的自定义域配置。
az containerapp env update -n MyContainerappEnvironment -g MyResourceGroup \
--dns-suffix my-suffix.net --certificate-file MyFilePath \
--certificate-password MyCertPass
可选参数
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
指向保存证书的 Azure Key Vault 机密的 URL。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境自定义域的证书文件 (.pfx 或 .pem)的文件路径。 若要管理容器应用的证书,请使用 az containerapp env certificate。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
使用 Azure Key Vault 进行身份验证的托管标识的资源 ID,或使用系统分配的标识。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境的自定义域的证书文件密码。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
环境的自定义域的 DNS 后缀。
| 属性 | 值 |
|---|---|
| Parameter group: | Custom Domain Arguments |
指示是否为环境启用了 mTLS 对等身份验证的布尔值。
| 属性 | 值 |
|---|---|
| Parameter group: | Peer Authentication Arguments |
| 接受的值: | false, true |
指示是否为环境启用对等流量加密的布尔值。
| 属性 | 值 |
|---|---|
| Parameter group: | Peer Traffic Configuration Arguments |
| 接受的值: | false, true |
一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
日志目标。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
| 接受的值: | azure-monitor, log-analytics, none |
指示是否分析 json 字符串日志到动态 json 列的布尔值。 仅适用于目标 log-analytics。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
| 接受的值: | false, true |
要向其发送诊断日志的 Log Analytics 工作区的工作区 ID。 仅适用于日志目标“log-analytics”。 可以使用“az monitor log-analytics workspace create”创建一个。 可能会应用额外的计费。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
用于配置 Log Analytics 工作区的 Log Analytics 工作区密钥。 仅适用于日志目标“log-analytics”。 可以使用“az monitor log-analytics workspace get-shared-keys”检索密钥。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
此工作负荷配置文件所需的最大节点 --workload-profile-name。
此工作负荷配置文件所需的最小节点 --workload-profile-name。
容器应用环境的名称。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
不等待长时间运行的操作完成。
| 属性 | 值 |
|---|---|
| 默认值: | False |
允许或阻止所有公共流量。
| 属性 | 值 |
|---|---|
| 接受的值: | Disabled, Enabled |
资源组的名称。 可以使用 az configure --defaults group=<name>配置默认组。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
用于 Azure Monitor 的存储帐户的名称或资源 ID。 如果提供此值,将自动创建 Azure Monitor 诊断设置。
| 属性 | 值 |
|---|---|
| Parameter group: | Monitoring Arguments |
订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。
| 属性 | 值 |
|---|---|
| Parameter group: | Resource Id Arguments |
空格分隔标记:key[=value] [key[=value] ...]。使用“”清除现有标记。
工作负荷配置文件的友好名称。
在此环境中添加或更新的工作负荷配置文件的类型,需要 --workload-profile-name。
全局参数
提高日志记录详细程度以显示所有调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |
显示此帮助消息并退出。
仅显示错误,禁止显示警告。
| 属性 | 值 |
|---|---|
| 默认值: | False |
输出格式。
| 属性 | 值 |
|---|---|
| 默认值: | json |
| 接受的值: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/。
增加日志记录详细程度。 使用 --debug 获取完整的调试日志。
| 属性 | 值 |
|---|---|
| 默认值: | False |