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

az cdn endpoint

管理 CDN 终结点。

命令

名称 说明 类型 状态
az cdn endpoint create

在指定的订阅、资源组和配置文件下创建具有指定终结点名称的新 CDN 终结点。

核心 GA
az cdn endpoint delete

删除具有指定订阅、资源组和配置文件下指定终结点名称的现有 CDN 终结点。

核心 GA
az cdn endpoint list

列出现有的 CDN 终结点。

核心 GA
az cdn endpoint load

将内容预加载到 CDN。 可用于 Verizon 配置文件。

核心 GA
az cdn endpoint name-exists

检查资源名称的可用性。 对于名称全局唯一(例如 CDN 终结点)的资源,这是必需的。

核心 GA
az cdn endpoint purge

从 CDN 中删除内容。

核心 GA
az cdn endpoint rule

管理终结点的传递规则。

核心 预览
az cdn endpoint rule action

管理终结点的传递规则操作。

核心 预览
az cdn endpoint rule action add

将操作添加到传递规则。

核心 预览
az cdn endpoint rule action remove

从传递规则中删除操作。

核心 预览
az cdn endpoint rule action show

使用终结点显示传递规则。

核心 预览
az cdn endpoint rule add

将传递规则添加到 CDN 终结点。

核心 预览
az cdn endpoint rule condition

管理终结点的传递规则条件。

核心 预览
az cdn endpoint rule condition add

向传递规则添加条件。

核心 预览
az cdn endpoint rule condition remove

从传递规则中删除条件。

核心 预览
az cdn endpoint rule condition show

显示与终结点关联的传递规则。

核心 预览
az cdn endpoint rule remove

从终结点中删除传递规则。

核心 预览
az cdn endpoint rule show

显示与终结点关联的传递规则。

核心 预览
az cdn endpoint show

获取具有指定订阅、资源组和配置文件下指定终结点名称的现有 CDN 终结点。

核心 GA
az cdn endpoint start

启动处于停止状态的现有 CDN 终结点。

核心 GA
az cdn endpoint stop

停止现有的正在运行的 CDN 终结点。

核心 GA
az cdn endpoint update

使用指定订阅、资源组和配置文件下的指定终结点名称更新新的 CDN 终结点。

核心 GA
az cdn endpoint validate-custom-domain

验证自定义域映射,以确保它映射到 DNS 中正确的 CDN 终结点。

核心 GA
az cdn endpoint wait

将 CLI 置于等待状态,直到满足条件。

核心 GA

az cdn endpoint create

在指定的订阅、资源组和配置文件下创建具有指定终结点名称的新 CDN 终结点。

az cdn endpoint create --endpoint-name
                       --origin
                       --profile-name
                       --resource-group
                       [--content-types-to-compress]
                       [--default-origin-group]
                       [--delivery-policy]
                       [--enable-compression {0, 1, f, false, n, no, t, true, y, yes}]
                       [--geo-filters]
                       [--location]
                       [--no-http {0, 1, f, false, n, no, t, true, y, yes}]
                       [--no-https {0, 1, f, false, n, no, t, true, y, yes}]
                       [--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
                       [--optimization-type {DynamicSiteAcceleration, GeneralMediaStreaming, GeneralWebDelivery, LargeFileDownload, VideoOnDemandMediaStreaming}]
                       [--origin-groups]
                       [--origin-host-header]
                       [--origin-path]
                       [--probe-path]
                       [--query-string-caching-behavior {BypassCaching, IgnoreQueryString, NotSet, UseQueryString}]
                       [--tags]
                       [--url-signing-keys]
                       [--web-application-firewall-policy-link]

示例

通过 HTTP 或 HTTPS 为主机名创建终结点以服务内容。

az cdn endpoint create -g group -n endpoint --profile-name profile --origin www.example.com

使用 HTTP 和 HTTPS 端口创建自定义域源的终结点。

az cdn endpoint create -g group -n endpoint --profile-name profile --origin www.example.com 88 4444

创建启用了专用链接的自定义域源的终结点。

az cdn endpoint create -g group -n endpoint --profile-name profile --origin www.example.com 80 443 /subscriptions/subid/resourcegroups/rg1/providers/Microsoft.Network/privateLinkServices/pls1 eastus "Please approve this request"

使用自定义域源创建仅限 https 的终结点,并支持Azure 内容分发网络的默认压缩 MIME 类型压缩。

az cdn endpoint create -g group -n endpoint --profile-name profile --origin www.example.com --no-http --enable-compression

使用自定义域源创建终结点,并支持特定 MIME 类型的压缩。

az cdn endpoint create -g group -n endpoint --profile-name profile --origin www.example.com --enable-compression --content-types-to-compress text/plain text/html

必需参数

--endpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--origin

由以下空格分隔的 7 元组指定的终结点源: www.example.com http_port https_port private_link_resource_id private_link_location private_link_approval_message origin_name。 HTTP 和 HTTPS 端口以及专用链接资源 ID 和位置是可选的。 HTTP 和 HTTPS 端口分别默认为 80 和 443。 专用链接字段仅对 sku Standard_Microsoft有效,如果设置了private_link_resource_id,则需要private_link_location。 源名称是可选的,默认为源。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

可选参数

--content-types-to-compress

要对其应用压缩的内容类型的列表。 该值应为有效的 MIME 类型。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--default-origin-group

用于源组的源组未显式包含在源组中。 可以指定为资源 ID 或此终结点的源组的名称。

--delivery-policy

一个策略,指定要用于终结点的传递规则。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--enable-compression

如果启用了压缩,则如果用户请求压缩版本,内容将作为压缩。 当请求的内容小于 1 字节或大于 1 MB 时,不会在 CDN 上压缩内容。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--geo-filters

定义 CDN 终结点中用户异地访问的规则列表。 每个地理筛选器定义对指定路径或内容的访问规则,例如阻止 APAC 用于路径 /pictures/Support 速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--location -l

资源位置。 如果未指定,将使用资源组的位置。

--no-http

禁用 HTTP 流量。指示终结点上是否不允许 HTTP 流量。 默认值为允许 HTTP 流量。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--no-https

指示终结点上是否不允许 HTTPS 流量。 默认值为允许 HTTPS 流量。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--no-wait

不等待长时间运行的操作完成。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--optimization-type

指定客户希望此 CDN 终结点针对哪些方案进行优化,例如下载媒体服务。 利用此信息,CDN 可以应用方案驱动的优化。

接受的值: DynamicSiteAcceleration, GeneralMediaStreaming, GeneralWebDelivery, LargeFileDownload, VideoOnDemandMediaStreaming
--origin-groups

源组由用于基于可用性对流量进行负载均衡的源组。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--origin-host-header

随每个请求发送到源的主机标头值。 仅当终结点使用单一源并且可由源中指定的同一属性重写时,才允许终结点中的此属性。如果将此保留为空,则请求主机名将确定此值。 Azure CDN 源(例如 Web 应用、Blob 存储和云服务)默认要求此主机头值与源主机名匹配。

--origin-path

CDN 可用于从中检索内容的源上的目录路径,例如 contoso.cloudapp.net/originpath。

--probe-path

源上托管的文件的路径,有助于加速动态内容的交付,并计算 CDN 的最佳路由。 这与源路径相对。 此属性仅在使用单个源时相关。

--query-string-caching-behavior

定义 CDN 如何缓存包含查询字符串的请求。 缓存时,可以忽略任何查询字符串,绕过缓存,以防止包含查询字符串的请求被缓存,或缓存每个请求的唯一 URL。

接受的值: BypassCaching, IgnoreQueryString, NotSet, UseQueryString
默认值: NotSet
--tags

资源标记。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--url-signing-keys

用于验证已签名 URL 哈希的密钥列表。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--web-application-firewall-policy-link

定义终结点(如果适用)的Web 应用程序防火墙策略,支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint delete

删除具有指定订阅、资源组和配置文件下指定终结点名称的现有 CDN 终结点。

az cdn endpoint delete [--endpoint-name]
                       [--ids]
                       [--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
                       [--profile-name]
                       [--resource-group]
                       [--subscription]

示例

删除 CDN 终结点。

az cdn endpoint delete -g group -n endpoint --profile-name profile-name

可选参数

--endpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--ids

一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。

--no-wait

不等待长时间运行的操作完成。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint list

列出现有的 CDN 终结点。

az cdn endpoint list --profile-name
                     --resource-group
                     [--max-items]
                     [--next-token]

示例

列出给定 CDN 配置文件中的所有终结点。

az cdn endpoint list -g group --profile-name profile-name

必需参数

--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

可选参数

--max-items

命令输出中要返回的项总数。 如果可用的项总数大于指定的值,则会在命令的输出中提供令牌。 若要恢复分页,请在后续命令的参数中 --next-token 提供令牌值。

--next-token

用于指定开始分页的位置的令牌。 这是先前截断的响应中的令牌值。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint load

将内容预加载到 CDN。 可用于 Verizon 配置文件。

az cdn endpoint load --content-paths
                     [--endpoint-name]
                     [--ids]
                     [--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
                     [--profile-name]
                     [--resource-group]
                     [--subscription]

示例

为终结点预加载 Javascript 和 CSS 内容。

az cdn endpoint load -g group -n endpoint --profile-name profile-name --content-paths '/scripts/app.js' '/styles/main.css'

必需参数

--content-paths

要加载的内容的路径。 路径应是源的相对文件 URL。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

可选参数

--endpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--ids

一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。

--no-wait

不等待长时间运行的操作完成。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint name-exists

检查资源名称的可用性。 对于名称全局唯一(例如 CDN 终结点)的资源,这是必需的。

az cdn endpoint name-exists --name
                            [--type {Microsoft.Cdn/Profiles/AfdEndpoints, Microsoft.Cdn/Profiles/Endpoints}]

示例

检查资源名称 contoso 是否可用。

az cdn name-exists --name contoso

必需参数

--name

要验证的资源名称。

可选参数

--type

要验证其名称的资源的类型。

接受的值: Microsoft.Cdn/Profiles/AfdEndpoints, Microsoft.Cdn/Profiles/Endpoints
默认值: Microsoft.Cdn/Profiles/Endpoints
全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint purge

从 CDN 中删除内容。

az cdn endpoint purge --content-paths
                      [--endpoint-name]
                      [--ids]
                      [--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
                      [--profile-name]
                      [--resource-group]
                      [--subscription]

示例

清除预加载的 Javascript 和 CSS 内容。

az cdn endpoint purge -g group -n endpoint --profile-name profile-name --content-paths '/scripts/app.js' '/styles/*'

必需参数

--content-paths

待清除内容的路径。 可以描述文件路径或野生卡目录。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

可选参数

--endpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--ids

一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。

--no-wait

不等待长时间运行的操作完成。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint show

获取具有指定订阅、资源组和配置文件下指定终结点名称的现有 CDN 终结点。

az cdn endpoint show [--endpoint-name]
                     [--ids]
                     [--profile-name]
                     [--resource-group]
                     [--subscription]

可选参数

--endpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--ids

一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。

--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint start

启动处于停止状态的现有 CDN 终结点。

az cdn endpoint start [--endpoint-nameendpoint-name]
                      [--ids]
                      [--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
                      [--profile-name]
                      [--resource-group]
                      [--subscription]

示例

启动 CDN 终结点。

az cdn endpoint start -g group -n endpoint --profile-name profile-name

可选参数

--endpoint-nameendpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--ids

一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。

--no-wait

不等待长时间运行的操作完成。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint stop

停止现有的正在运行的 CDN 终结点。

az cdn endpoint stop [--endpoint-name]
                     [--ids]
                     [--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
                     [--profile-name]
                     [--resource-group]
                     [--subscription]

示例

停止 CDN 终结点。

az cdn endpoint stop -g group -n endpoint --profile-name profile-name

可选参数

--endpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--ids

一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。

--no-wait

不等待长时间运行的操作完成。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint update

使用指定订阅、资源组和配置文件下的指定终结点名称更新新的 CDN 终结点。

az cdn endpoint update [--add]
                       [--content-types-to-compress]
                       [--default-origin-group]
                       [--delivery-policy]
                       [--enable-compression {0, 1, f, false, n, no, t, true, y, yes}]
                       [--endpoint-name]
                       [--force-string {0, 1, f, false, n, no, t, true, y, yes}]
                       [--geo-filters]
                       [--ids]
                       [--location]
                       [--no-http {0, 1, f, false, n, no, t, true, y, yes}]
                       [--no-https {0, 1, f, false, n, no, t, true, y, yes}]
                       [--no-wait {0, 1, f, false, n, no, t, true, y, yes}]
                       [--optimization-type {DynamicSiteAcceleration, GeneralMediaStreaming, GeneralWebDelivery, LargeFileDownload, VideoOnDemandMediaStreaming}]
                       [--origin-groups]
                       [--origin-host-header]
                       [--origin-path]
                       [--probe-path]
                       [--profile-name]
                       [--query-string-caching-behavior {BypassCaching, IgnoreQueryString, NotSet, UseQueryString}]
                       [--remove]
                       [--resource-group]
                       [--set]
                       [--subscription]
                       [--tags]
                       [--url-signing-keys]
                       [--web-application-firewall-policy-link]

示例

关闭终结点的 HTTP 流量。

az cdn endpoint update -g group -n endpoint --profile-name profile --no-http

为终结点启用内容压缩。

az cdn endpoint update -g group -n endpoint --profile-name profile --enable-compression

可选参数

--add

通过指定路径和键值对将对象添加到对象列表。 示例:--add property.listProperty <key=value、string 或 JSON 字符串>。

--content-types-to-compress

要对其应用压缩的内容类型的列表。 该值应为有效的 MIME 类型。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--default-origin-group

用于源组的源组未显式包含在源组中。 可以指定为资源 ID 或此终结点的源组的名称。

--delivery-policy

一个策略,指定要用于终结点的传递规则。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--enable-compression

如果启用了压缩,则如果用户请求压缩版本,内容将作为压缩。 当请求的内容小于 1 字节或大于 1 MB 时,不会在 CDN 上压缩内容。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--endpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--force-string

使用“set”或“add”时,保留字符串文本,而不是尝试转换为 JSON。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--geo-filters

定义 CDN 终结点中用户异地访问的规则列表。 每个地理筛选器定义对指定路径或内容的访问规则,例如阻止 APAC 用于路径 /pictures/Support 速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--ids

一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。

--location -l

资源位置。

--no-http

禁用 HTTP 流量。指示终结点上是否不允许 HTTP 流量。 默认值为允许 HTTP 流量。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--no-https

指示终结点上是否不允许 HTTPS 流量。 默认值为允许 HTTPS 流量。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--no-wait

不等待长时间运行的操作完成。

接受的值: 0, 1, f, false, n, no, t, true, y, yes
--optimization-type

指定客户希望此 CDN 终结点针对哪些方案进行优化,例如下载媒体服务。 利用此信息,CDN 可以应用方案驱动的优化。

接受的值: DynamicSiteAcceleration, GeneralMediaStreaming, GeneralWebDelivery, LargeFileDownload, VideoOnDemandMediaStreaming
--origin-groups

源组由用于基于可用性对流量进行负载均衡的源组。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--origin-host-header

随每个请求发送到源的主机标头值。 仅当终结点使用单一源并且可由源中指定的同一属性重写时,才允许终结点中的此属性。如果将此保留为空,则请求主机名将确定此值。 Azure CDN 源(例如 Web 应用、Blob 存储和云服务)默认要求此主机头值与源主机名匹配。

--origin-path

CDN 可用于从中检索内容的源上的目录路径,例如 contoso.cloudapp.net/originpath。

--probe-path

源上托管的文件的路径,有助于加速动态内容的交付,并计算 CDN 的最佳路由。 这与源路径相对。 此属性仅在使用单个源时相关。

--profile-name

资源组中唯一的 CDN 配置文件的名称。

--query-string-caching-behavior

定义 CDN 如何缓存包含查询字符串的请求。 缓存时,可以忽略任何查询字符串,绕过缓存,以防止包含查询字符串的请求被缓存,或缓存每个请求的唯一 URL。

接受的值: BypassCaching, IgnoreQueryString, NotSet, UseQueryString
--remove

从列表中删除属性或元素。 示例:--remove property.list OR --remove propertyToRemove。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

--set

通过指定要设置的属性路径和值来更新对象。 示例:--set property1.property2=。

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--tags

资源标记。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--url-signing-keys

用于验证已签名 URL 哈希的密钥列表。 支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

--web-application-firewall-policy-link

定义终结点(如果适用)的Web 应用程序防火墙策略,支持速记语法、json-file 和 yaml-file。 请尝试“??” 以显示更多内容。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint validate-custom-domain

验证自定义域映射,以确保它映射到 DNS 中正确的 CDN 终结点。

az cdn endpoint validate-custom-domain --host-name
                                       [--endpoint-name]
                                       [--ids]
                                       [--profile-name]
                                       [--resource-group]
                                       [--subscription]

示例

验证域 www.contoso.com 以查看它是否映射到 DNS 中的正确 CDN 终结点。

az cdn endpoint validate-custom-domain -g group -n endpoint --profile-name profile-name --host-name www.contoso.com

必需参数

--host-name

自定义域的主机名。 必须是域名。

可选参数

--endpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--ids

一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。

--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。

az cdn endpoint wait

将 CLI 置于等待状态,直到满足条件。

az cdn endpoint wait [--created]
                     [--custom]
                     [--deleted]
                     [--endpoint-name]
                     [--exists]
                     [--ids]
                     [--interval]
                     [--profile-name]
                     [--resource-group]
                     [--subscription]
                     [--timeout]
                     [--updated]

可选参数

--created

等待在“Succeeded”中使用“provisioningState”创建。

默认值: False
--custom

等待条件满足自定义 JMESPath 查询。 例如 provisioningState!='InProgress', instanceView.statuses[?code=='PowerState/running']。

--deleted

等到删除为止。

默认值: False
--endpoint-name --name -n

全局唯一的配置文件下的终结点的名称。

--exists

等待资源存在。

默认值: False
--ids

一个或多个资源 ID(以空格分隔)。 它应该是包含“Resource Id”参数的所有信息的完整资源 ID。 应提供 --ids 或其他“Resource Id”参数。

--interval

轮询间隔(以秒为单位)。

默认值: 30
--profile-name

资源组中唯一的 CDN 配置文件的名称。

--resource-group -g

资源组的名称。 可以使用 az configure --defaults group=<name> 配置默认组。

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--timeout

最大等待(以秒为单位)。

默认值: 3600
--updated

等到 provisioningState 更新为“Succeeded”。

默认值: False
全局参数
--debug

提高日志记录详细程度以显示所有调试日志。

--help -h

显示此帮助消息并退出。

--only-show-errors

只显示错误,取消显示警告。

--output -o

输出格式。

接受的值: json, jsonc, none, table, tsv, yaml, yamlc
默认值: json
--query

JMESPath 查询字符串。 有关更多信息和示例,请参阅 http://jmespath.org/

--subscription

订阅的名称或 ID。 可以使用 az account set -s NAME_OR_ID 配置默认订阅。

--verbose

提高日志记录详细程度。 使用 --debug 获取完整的调试日志。