你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
Remove-AzApiManagementGatewayHostnameConfiguration
从现有网关中删除主机名配置。
语法
Remove-AzApiManagementGatewayHostnameConfiguration
-Context <PsApiManagementContext>
-GatewayId <String>
-GatewayHostnameConfigurationId <String>
[-PassThru]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Remove-AzApiManagementGatewayHostnameConfiguration
-InputObject <PsApiManagementGatewayHostnameConfiguration>
[-PassThru]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Remove-AzApiManagementGatewayHostnameConfiguration
-ResourceId <String>
[-PassThru]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
说明
Remove-AzApiManagementGatewayHostnameConfiguration cmdlet 从现有网关中删除主机名配置。
示例
示例 1:删除现有的网关主机名配置
$apimContext = New-AzApiManagementContext -ResourceGroupName "Api-Default-WestUS" -ServiceName "contoso"
Remove-AzApiManagementGatewayHostnameConfiguration -Context $apimContext -GatewayId "g0001" -GatewayHostnameConfigurationId "h0001"
此命令将删除现有的网关主机名配置,并且不会提示用户进行确认。
参数
-Confirm
在运行 cmdlet 之前,提示你进行确认。
类型: | SwitchParameter |
别名: | cf |
Position: | Named |
默认值: | None |
必需: | False |
接受管道输入: | False |
接受通配符: | False |
-Context
PsApiManagementContext 的实例。 此参数是必需的。
类型: | PsApiManagementContext |
Position: | Named |
默认值: | None |
必需: | True |
接受管道输入: | True |
接受通配符: | False |
-DefaultProfile
用于与 Azure 通信的凭据、帐户、租户和订阅。
类型: | IAzureContextContainer |
别名: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
默认值: | None |
必需: | False |
接受管道输入: | False |
接受通配符: | False |
-GatewayHostnameConfigurationId
现有网关主机名配置的标识符。 此参数是必需的。
类型: | String |
Position: | Named |
默认值: | None |
必需: | True |
接受管道输入: | True |
接受通配符: | False |
-GatewayId
现有网关的标识符。 此参数是必需的。
类型: | String |
Position: | Named |
默认值: | None |
必需: | True |
接受管道输入: | True |
接受通配符: | False |
-InputObject
PsApiManagementGatewayHostnameConfiguration 的实例。 此参数是必需的。
类型: | PsApiManagementGatewayHostnameConfiguration |
Position: | Named |
默认值: | None |
必需: | True |
接受管道输入: | True |
接受通配符: | False |
-PassThru
如果指定操作成功,则为 true。 此参数是可选的。 默认值为 false。
类型: | SwitchParameter |
Position: | Named |
默认值: | None |
必需: | False |
接受管道输入: | True |
接受通配符: | False |
-ResourceId
GatewayHostnameConfiguration 的 Arm ResourceId。 此参数是必需的。
类型: | String |
Position: | Named |
默认值: | None |
必需: | True |
接受管道输入: | True |
接受通配符: | False |
-WhatIf
显示 cmdlet 运行时会发生什么情况。 cmdlet 未运行。
类型: | SwitchParameter |
别名: | wi |
Position: | Named |
默认值: | None |
必需: | False |
接受管道输入: | False |
接受通配符: | False |