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

az iot ops ns device endpoint inbound add

Note

此参考是 Azure CLI(版本 2.67.0 或更高版本)的 azure-iot-ops 扩展的一部分。 该扩展将在首次运行 az iot ops ns device endpoint inbound add 命令时自动安装。 了解更多关于扩展的信息。

命令组“iot ops ns”处于预览状态,正在开发中。 参考和支持级别:https://aka.ms/CLI_refstatus

将入站终结点添加到设备注册表命名空间中的设备。

命令

名称 说明 类型 Status
az iot ops ns device endpoint inbound add custom

将自定义入站终结点添加到设备注册表命名空间中的设备。

Extension Preview
az iot ops ns device endpoint inbound add media

将媒体入站终结点添加到设备注册表命名空间中的设备。

Extension Preview
az iot ops ns device endpoint inbound add mqtt

将 MQTT 入站终结点添加到设备注册表命名空间中的设备。

Extension Preview
az iot ops ns device endpoint inbound add onvif

将 ONVIF 入站终结点添加到设备注册表命名空间中的设备。

Extension Preview
az iot ops ns device endpoint inbound add opcua

将 OPC UA 入站终结点添加到设备注册表命名空间中的设备。

Extension Preview
az iot ops ns device endpoint inbound add rest

将 Rest 入站终结点添加到设备注册表命名空间中的设备。

Extension Preview
az iot ops ns device endpoint inbound add sse

将 SSE 入站终结点添加到设备注册表命名空间中的设备。

Extension Preview

az iot ops ns device endpoint inbound add custom

预览

命令组“iot ops ns”处于预览状态,正在开发中。 参考和支持级别:https://aka.ms/CLI_refstatus

将自定义入站终结点添加到设备注册表命名空间中的设备。

自定义终结点允许定义自己的终结点类型和配置。

az iot ops ns device endpoint inbound add custom --address --endpoint-address
                                                 --device
                                                 --endpoint-type --type
                                                 --instance
                                                 --name
                                                 --resource-group
                                                 [--additional-config --config]
                                                 [--cert-ref --certificate-ref]
                                                 [--icr --intermediate-cert-ref]
                                                 [--key-ref]
                                                 [--pass-ref --password-ref]
                                                 [--replace {false, true}]
                                                 [--trust-list]
                                                 [--user-ref --username-ref]
                                                 [--version]

示例

将基本自定义终结点添加到设备

az iot ops ns device endpoint inbound add custom --device mydevice --instance myInstance -g myInstanceResourceGroup --name myCustomEndpoint --endpoint-type "Custom.Type" --endpoint-address "192.168.1.100:8080"

添加具有身份验证的自定义终结点

az iot ops ns device endpoint inbound add custom --device mydevice --instance myInstance -g myInstanceResourceGroup --name myCustomEndpoint --endpoint-type "Custom.Type" --endpoint-address "192.168.1.100:8080" --user-ref auth-secret/username --pass-ref auth-secret/password

添加具有证书身份验证和版本的自定义终结点

az iot ops ns device endpoint inbound add custom --device mydevice --instance myInstance -g myInstanceResourceGroup --name myCustomEndpoint --endpoint-type "Custom.Type" --endpoint-address "192.168.1.100:8080" --cert-ref cert-secret/certificate --version "1.0"

添加具有增强证书身份验证(包括私钥)的自定义终结点

az iot ops ns device endpoint inbound add custom --device mydevice --instance myInstance -g myInstanceResourceGroup --name myCustomEndpoint --endpoint-type "Custom.Type" --endpoint-address "192.168.1.100:8080" --cert-ref cert-secret/certificate --key-ref cert-secret/privateKey

添加包含证书身份验证的自定义终结点,包括中间证书

az iot ops ns device endpoint inbound add custom --device mydevice --instance myInstance -g myInstanceResourceGroup --name myCustomEndpoint --endpoint-type "Custom.Type" --endpoint-address "192.168.1.100:8080" --cert-ref cert-secret/certificate --icr cert-secret/intermediateCerts

添加具有完整证书链身份验证的自定义终结点

az iot ops ns device endpoint inbound add custom --device mydevice --instance myInstance -g myInstanceResourceGroup --name myCustomEndpoint --endpoint-type "Custom.Type" --endpoint-address "192.168.1.100:8080" --cert-ref cert-secret/certificate --key-ref cert-secret/privateKey --icr cert-secret/intermediateCerts

添加具有其他配置的自定义终结点

az iot ops ns device endpoint inbound add custom --device mydevice --instance myInstance -g myInstanceResourceGroup --name myCustomEndpoint --endpoint-type "Custom.Type" --endpoint-address "192.168.1.100:8080" --additional-config "{\"customSetting\": \"value\"}"

必需参数

--address --endpoint-address

要连接到的终结点地址。

--device -d

设备名称。

--endpoint-type --type

自定义终结点的类型。

--instance -i

Azure IoT作实例的名称。

--name -n

终结点名称。

--resource-group -g

Azure IoT作实例的资源组。

可选参数

以下参数是可选的,但根据上下文,命令可能需要一个或多个参数才能成功执行。

--additional-config --config

JSON 格式的自定义终结点的其他配置。

--cert-ref --certificate-ref

身份验证中使用的证书参考。

属性
参数组: Authentication Arguments
--icr --intermediate-cert-ref

证书身份验证的中间证书参考。

属性
参数组: Authentication Arguments
--key-ref

证书身份验证的私钥参考。

属性
参数组: Authentication Arguments
--pass-ref --password-ref

身份验证中使用的密码参考。

属性
参数组: Authentication Arguments
--replace

如果已有同名的另一个终结点,则替换该终结点。

属性
默认值: False
接受的值: false, true
--trust-list

终结点的受信任证书列表。

--user-ref --username-ref

身份验证中使用的用户名参考。

属性
参数组: Authentication Arguments
--version

终结点版本。

全局参数
--debug

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

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

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

属性
默认值: False
--output -o

输出格式。

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

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

--subscription

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

--verbose

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

属性
默认值: False

az iot ops ns device endpoint inbound add media

预览

命令组“iot ops ns”处于预览状态,正在开发中。 参考和支持级别:https://aka.ms/CLI_refstatus

将媒体入站终结点添加到设备注册表命名空间中的设备。

有关媒体连接器的详细信息,请参阅 https://aka.ms/aio-media-quickstart

az iot ops ns device endpoint inbound add media --address --endpoint-address
                                                --device
                                                --instance
                                                --name
                                                --resource-group
                                                [--pass-ref --password-ref]
                                                [--replace {false, true}]
                                                [--user-ref --username-ref]
                                                [--version]

示例

将基本媒体终结点添加到设备

az iot ops ns device endpoint inbound add media --device mydevice --instance myInstance -g myInstanceResourceGroup --name myCameraEndpoint --endpoint-address "rtsp://192.168.1.100:554/stream"

添加具有身份验证的媒体终结点

az iot ops ns device endpoint inbound add media --device mydevice --instance myInstance -g myInstanceResourceGroup --name myCameraEndpoint --endpoint-address "rtsp://192.168.1.100:554/stream" --user-ref auth-secret/username --pass-ref auth-secret/password

必需参数

--address --endpoint-address

要连接到的终结点地址。

--device -d

设备名称。

--instance -i

Azure IoT作实例的名称。

--name -n

终结点名称。

--resource-group -g

Azure IoT作实例的资源组。

可选参数

以下参数是可选的,但根据上下文,命令可能需要一个或多个参数才能成功执行。

--pass-ref --password-ref

身份验证中使用的密码参考。

属性
参数组: Authentication Arguments
--replace

如果已有同名的另一个终结点,则替换该终结点。

属性
默认值: False
接受的值: false, true
--user-ref --username-ref

身份验证中使用的用户名参考。

属性
参数组: Authentication Arguments
--version

终结点版本。

全局参数
--debug

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

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

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

属性
默认值: False
--output -o

输出格式。

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

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

--subscription

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

--verbose

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

属性
默认值: False

az iot ops ns device endpoint inbound add mqtt

预览

命令组“iot ops ns”处于预览状态,正在开发中。 参考和支持级别:https://aka.ms/CLI_refstatus

将 MQTT 入站终结点添加到设备注册表命名空间中的设备。

az iot ops ns device endpoint inbound add mqtt --address --endpoint-address
                                               --device
                                               --instance
                                               --name
                                               --resource-group
                                               [--replace {false, true}]
                                               [--version]

示例

将基本 MQTT 终结点添加到连接到群集中代理的设备

az iot ops ns device endpoint inbound add mqtt --device mydevice --instance myInstance -g myInstanceResourceGroup --name myMqttEndpoint --endpoint-address "aio-broker:18883"

添加具有版本规范的 MQTT 终结点

az iot ops ns device endpoint inbound add mqtt --device mydevice --instance myInstance -g myInstanceResourceGroup --name myMqttEndpoint --endpoint-address "aio-broker:18883" --version "0.3.4"

必需参数

--address --endpoint-address

要连接到的终结点地址。

--device -d

设备名称。

--instance -i

Azure IoT作实例的名称。

--name -n

终结点名称。

--resource-group -g

Azure IoT作实例的资源组。

可选参数

以下参数是可选的,但根据上下文,命令可能需要一个或多个参数才能成功执行。

--replace

如果已有同名的另一个终结点,则替换该终结点。

属性
默认值: False
接受的值: false, true
--version

终结点版本。

全局参数
--debug

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

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

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

属性
默认值: False
--output -o

输出格式。

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

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

--subscription

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

--verbose

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

属性
默认值: False

az iot ops ns device endpoint inbound add onvif

预览

命令组“iot ops ns”处于预览状态,正在开发中。 参考和支持级别:https://aka.ms/CLI_refstatus

将 ONVIF 入站终结点添加到设备注册表命名空间中的设备。

有关 ONVIF 连接器的详细信息,请参阅 https://aka.ms/aio-onvif-quickstart

az iot ops ns device endpoint inbound add onvif --address --endpoint-address
                                                --device
                                                --instance
                                                --name
                                                --resource-group
                                                [--accept-invalid-certificates --aic {false, true}]
                                                [--accept-invalid-hostnames --aih {false, true}]
                                                [--pass-ref --password-ref]
                                                [--replace {false, true}]
                                                [--user-ref --username-ref]
                                                [--version]

示例

将基本 ONVIF 终结点添加到设备

az iot ops ns device endpoint inbound add onvif --device mydevice --instance myInstance -g myInstanceResourceGroup --name myONVIFEndpoint --endpoint-address "http://192.168.1.100:8000/onvif/device_service"

添加具有身份验证的 ONVIF 终结点

az iot ops ns device endpoint inbound add onvif --device mydevice --instance myInstance -g myInstanceResourceGroup --name myONVIFEndpoint --endpoint-address "http://192.168.1.100:8000/onvif/device_service" --user-ref auth-secret/username --pass-ref auth-secret/password

添加接受无效主机名和证书的 ONVIF 终结点

az iot ops ns device endpoint inbound add onvif --device mydevice --instance myInstance -g myInstanceResourceGroup --name myONVIFEndpoint --endpoint-address "https://192.168.1.100:8000/onvif/device_service" --accept-invalid-hostnames --accept-invalid-certificates

必需参数

--address --endpoint-address

要连接到的终结点地址。

--device -d

设备名称。

--instance -i

Azure IoT作实例的名称。

--name -n

终结点名称。

--resource-group -g

Azure IoT作实例的资源组。

可选参数

以下参数是可选的,但根据上下文,命令可能需要一个或多个参数才能成功执行。

--accept-invalid-certificates --aic

接受无效证书。

属性
参数组: ONVIF Configuration Arguments
默认值: False
接受的值: false, true
--accept-invalid-hostnames --aih

接受证书中的无效主机名。

属性
参数组: ONVIF Configuration Arguments
默认值: False
接受的值: false, true
--pass-ref --password-ref

身份验证中使用的密码参考。

属性
参数组: Authentication Arguments
--replace

如果已有同名的另一个终结点,则替换该终结点。

属性
默认值: False
接受的值: false, true
--user-ref --username-ref

身份验证中使用的用户名参考。

属性
参数组: Authentication Arguments
--version

终结点版本。

全局参数
--debug

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

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

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

属性
默认值: False
--output -o

输出格式。

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

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

--subscription

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

--verbose

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

属性
默认值: False

az iot ops ns device endpoint inbound add opcua

预览

命令组“iot ops ns”处于预览状态,正在开发中。 参考和支持级别:https://aka.ms/CLI_refstatus

将 OPC UA 入站终结点添加到设备注册表命名空间中的设备。

有关 OPC UA 连接器的详细信息,请参阅 https://aka.ms/aio-opcua-quickstart

az iot ops ns device endpoint inbound add opcua --address --endpoint-address
                                                --device
                                                --instance
                                                --name
                                                --resource-group
                                                [--ac --accept-certs {false, true}]
                                                [--ad --run-asset-discovery {false, true}]
                                                [--app --application-name]
                                                [--keep-alive]
                                                [--key-frame-count --kfc]
                                                [--pass-ref --password-ref]
                                                [--pi --publishing-interval]
                                                [--qs --queue-size]
                                                [--replace {false, true}]
                                                [--sampling-interval --si]
                                                [--sbo --session-backoff]
                                                [--security-mode --sm {none, sign, signAndEncrypt}]
                                                [--security-policy --sp {Aes128_Sha256_RsaOaep, Aes256_Sha256_RsaPss, Basic128Rsa15, Basic256, Basic256Sha256, None}]
                                                [--session-keep-alive --ska]
                                                [--session-reconnect --srp]
                                                [--session-timeout]
                                                [--session-tracing --str {false, true}]
                                                [--slt --subscription-lifetime]
                                                [--smi --subscription-max-items]
                                                [--user-ref --username-ref]
                                                [--version]

示例

将基本 OPC UA 终结点添加到设备

az iot ops ns device endpoint inbound add opcua --device mydevice --instance myInstance -g myInstanceResourceGroup --name myOPCUAEndpoint --endpoint-address "opc.tcp://192.168.1.100:4840"

添加具有身份验证的 OPC UA 终结点

az iot ops ns device endpoint inbound add opcua --device mydevice --instance myInstance -g myInstanceResourceGroup --name myOPCUAEndpoint --endpoint-address "opc.tcp://192.168.1.100:4840" --user-ref auth-secret/username --pass-ref auth-secret/password

添加具有自定义应用程序名称的 OPC UA 终结点

az iot ops ns device endpoint inbound add opcua --device mydevice --instance myInstance -g myInstanceResourceGroup --name myOPCUAEndpoint --endpoint-address "opc.tcp://192.168.1.100:4840" --application-name "My OPC UA App"

添加具有自定义会话参数的 OPC UA 终结点

az iot ops ns device endpoint inbound add opcua --device mydevice --instance myInstance -g myInstanceResourceGroup --name myOPCUAEndpoint --endpoint-address "opc.tcp://192.168.1.100:4840" --keep-alive 15000 --session-timeout 90000 --publishing-interval 2000 --sampling-interval 1500

添加启用了安全设置和资产发现的 OPC UA 终结点

az iot ops ns device endpoint inbound add opcua --device mydevice --instance myInstance -g myInstanceResourceGroup --name myOPCUAEndpoint --endpoint-address "opc.tcp://192.168.1.100:4840" --security-policy "Basic256Sha256" --security-mode "SignAndEncrypt" --run-asset-discovery

必需参数

--address --endpoint-address

要连接到的终结点地址。

--device -d

设备名称。

--instance -i

Azure IoT作实例的名称。

--name -n

终结点名称。

--resource-group -g

Azure IoT作实例的资源组。

可选参数

以下参数是可选的,但根据上下文,命令可能需要一个或多个参数才能成功执行。

--ac --accept-certs

自动接受不受信任的服务器证书。

属性
参数组: Security Arguments
默认值: False
接受的值: false, true
--ad --run-asset-discovery

连接到终结点后启用资产发现。

属性
参数组: Configuration Arguments
默认值: False
接受的值: false, true
--app --application-name

OPC UA 客户端的应用程序名称。

属性
参数组: Configuration Arguments
默认值: OPC UA Broker
--keep-alive

保持活动时间(以毫秒为单位)。

属性
参数组: Configuration Arguments
默认值: 10000
--key-frame-count --kfc

关键帧计数。

属性
参数组: Configuration Arguments
默认值: 0
--pass-ref --password-ref

身份验证中使用的密码参考。

属性
参数组: Authentication Arguments
--pi --publishing-interval

发布间隔(以毫秒为单位)。

属性
参数组: Configuration Arguments
默认值: 1000
--qs --queue-size

队列大小。

属性
参数组: Configuration Arguments
默认值: 1
--replace

如果已有同名的另一个终结点,则替换该终结点。

属性
默认值: False
接受的值: false, true
--sampling-interval --si

采样间隔(以毫秒为单位)。

属性
参数组: Configuration Arguments
默认值: 1000
--sbo --session-backoff

会话重新连接指数回退(以毫秒为单位)。

属性
参数组: Session Arguments
默认值: 10000
--security-mode --sm

用于连接的安全模式。

属性
参数组: Security Arguments
接受的值: none, sign, signAndEncrypt
--security-policy --sp

用于连接的安全策略。

属性
参数组: Security Arguments
接受的值: Aes128_Sha256_RsaOaep, Aes256_Sha256_RsaPss, Basic128Rsa15, Basic256, Basic256Sha256, None
--session-keep-alive --ska

会话保持活动间隔(以毫秒为单位)。

属性
参数组: Session Arguments
默认值: 10000
--session-reconnect --srp

会话重新连接周期(以毫秒为单位)。

属性
参数组: Session Arguments
默认值: 2000
--session-timeout

会话超时(以毫秒为单位)。

属性
参数组: Session Arguments
默认值: 60000
--session-tracing --str

为会话启用跟踪标头。

属性
参数组: Session Arguments
默认值: False
接受的值: false, true
--slt --subscription-lifetime

订阅生存期(以毫秒为单位)。

属性
参数组: Subscription Arguments
默认值: 60000
--smi --subscription-max-items

订阅中的最大项数。

属性
参数组: Subscription Arguments
默认值: 1000
--user-ref --username-ref

身份验证中使用的用户名参考。

属性
参数组: Authentication Arguments
--version

终结点版本。

全局参数
--debug

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

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

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

属性
默认值: False
--output -o

输出格式。

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

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

--subscription

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

--verbose

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

属性
默认值: False

az iot ops ns device endpoint inbound add rest

预览

命令组“iot ops ns”处于预览状态,正在开发中。 参考和支持级别:https://aka.ms/CLI_refstatus

将 Rest 入站终结点添加到设备注册表命名空间中的设备。

az iot ops ns device endpoint inbound add rest --address --endpoint-address
                                               --device
                                               --instance
                                               --name
                                               --resource-group
                                               [--cert-ref --certificate-ref]
                                               [--icr --intermediate-cert-ref]
                                               [--key-ref]
                                               [--pass-ref --password-ref]
                                               [--replace {false, true}]
                                               [--user-ref --username-ref]
                                               [--version]

示例

将基本 rest 终结点添加到设备

az iot ops ns device endpoint inbound add rest --device mydevice --instance myInstance -g myInstanceResourceGroup --name myEndpoint --endpoint-address "https://api.example.com/data"

添加具有身份验证的 rest 终结点

az iot ops ns device endpoint inbound add rest --device mydevice --instance myInstance -g myInstanceResourceGroup --name myEndpoint --endpoint-address "https://api.example.com/data" --user-ref auth-secret/username --pass-ref auth-secret/password

添加具有证书身份验证的 rest 终结点

az iot ops ns device endpoint inbound add rest --device mydevice --instance myInstance -g myInstanceResourceGroup --name myEndpoint --endpoint-address "https://api.example.com/data" --cert-ref cert-secret/certificate

添加具有增强证书身份验证(包括私钥)的 rest 终结点

az iot ops ns device endpoint inbound add rest --device mydevice --instance myInstance -g myInstanceResourceGroup --name myEndpoint --endpoint-address "https://api.example.com/data" --cert-ref cert-secret/certificate --key-ref cert-secret/privateKey

添加包含证书身份验证的 rest 终结点,包括中间证书

az iot ops ns device endpoint inbound add rest --device mydevice --instance myInstance -g myInstanceResourceGroup --name myEndpoint --endpoint-address "https://api.example.com/data" --cert-ref cert-secret/certificate --icr cert-secret/intermediateCerts

添加具有完整证书链身份验证的 Rest 终结点

az iot ops ns device endpoint inbound add rest --device mydevice --instance myInstance -g myInstanceResourceGroup --name myEndpoint --endpoint-address "https://api.example.com/data" --cert-ref cert-secret/certificate --key-ref cert-secret/privateKey --icr cert-secret/intermediateCerts

必需参数

--address --endpoint-address

要连接到的终结点地址。

--device -d

设备名称。

--instance -i

Azure IoT作实例的名称。

--name -n

终结点名称。

--resource-group -g

Azure IoT作实例的资源组。

可选参数

以下参数是可选的,但根据上下文,命令可能需要一个或多个参数才能成功执行。

--cert-ref --certificate-ref

身份验证中使用的证书参考。

属性
参数组: Authentication Arguments
--icr --intermediate-cert-ref

证书身份验证的中间证书参考。

属性
参数组: Authentication Arguments
--key-ref

证书身份验证的私钥参考。

属性
参数组: Authentication Arguments
--pass-ref --password-ref

身份验证中使用的密码参考。

属性
参数组: Authentication Arguments
--replace

如果已有同名的另一个终结点,则替换该终结点。

属性
默认值: False
接受的值: false, true
--user-ref --username-ref

身份验证中使用的用户名参考。

属性
参数组: Authentication Arguments
--version

终结点版本。

全局参数
--debug

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

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

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

属性
默认值: False
--output -o

输出格式。

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

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

--subscription

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

--verbose

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

属性
默认值: False

az iot ops ns device endpoint inbound add sse

预览

命令组“iot ops ns”处于预览状态,正在开发中。 参考和支持级别:https://aka.ms/CLI_refstatus

将 SSE 入站终结点添加到设备注册表命名空间中的设备。

az iot ops ns device endpoint inbound add sse --address --endpoint-address
                                              --device
                                              --instance
                                              --name
                                              --resource-group
                                              [--cert-ref --certificate-ref]
                                              [--icr --intermediate-cert-ref]
                                              [--key-ref]
                                              [--pass-ref --password-ref]
                                              [--replace {false, true}]
                                              [--user-ref --username-ref]
                                              [--version]

示例

将基本 SSE 终结点添加到设备

az iot ops ns device endpoint inbound add sse --device mydevice --instance myInstance -g myInstanceResourceGroup --name mySSEEndpoint --endpoint-address "https://events.example.com/stream"

添加具有身份验证的 SSE 终结点

az iot ops ns device endpoint inbound add sse --device mydevice --instance myInstance -g myInstanceResourceGroup --name mySSEEndpoint --endpoint-address "https://events.example.com/stream" --user-ref auth-secret/username --pass-ref auth-secret/password

添加具有证书身份验证的 SSE 终结点

az iot ops ns device endpoint inbound add sse --device mydevice --instance myInstance -g myInstanceResourceGroup --name mySSEEndpoint --endpoint-address "https://events.example.com/stream" --cert-ref cert-secret/certificate

添加具有增强证书身份验证(包括私钥)的 SSE 终结点

az iot ops ns device endpoint inbound add sse --device mydevice --instance myInstance -g myInstanceResourceGroup --name mySSEEndpoint --endpoint-address "https://events.example.com/stream" --cert-ref cert-secret/certificate --key-ref cert-secret/privateKey

添加包含证书身份验证的 SSE 终结点,包括中间证书

az iot ops ns device endpoint inbound add sse --device mydevice --instance myInstance -g myInstanceResourceGroup --name mySSEEndpoint --endpoint-address "https://events.example.com/stream" --cert-ref cert-secret/certificate --icr cert-secret/intermediateCerts

添加具有完整证书链身份验证的 SSE 终结点

az iot ops ns device endpoint inbound add sse --device mydevice --instance myInstance -g myInstanceResourceGroup --name mySSEEndpoint --endpoint-address "https://events.example.com/stream" --cert-ref cert-secret/certificate --key-ref cert-secret/privateKey --icr cert-secret/intermediateCerts

必需参数

--address --endpoint-address

要连接到的终结点地址。

--device -d

设备名称。

--instance -i

Azure IoT作实例的名称。

--name -n

终结点名称。

--resource-group -g

Azure IoT作实例的资源组。

可选参数

以下参数是可选的,但根据上下文,命令可能需要一个或多个参数才能成功执行。

--cert-ref --certificate-ref

身份验证中使用的证书参考。

属性
参数组: Authentication Arguments
--icr --intermediate-cert-ref

证书身份验证的中间证书参考。

属性
参数组: Authentication Arguments
--key-ref

证书身份验证的私钥参考。

属性
参数组: Authentication Arguments
--pass-ref --password-ref

身份验证中使用的密码参考。

属性
参数组: Authentication Arguments
--replace

如果已有同名的另一个终结点,则替换该终结点。

属性
默认值: False
接受的值: false, true
--user-ref --username-ref

身份验证中使用的用户名参考。

属性
参数组: Authentication Arguments
--version

终结点版本。

全局参数
--debug

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

属性
默认值: False
--help -h

显示此帮助消息并退出。

--only-show-errors

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

属性
默认值: False
--output -o

输出格式。

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

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

--subscription

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

--verbose

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

属性
默认值: False