Get-AzVirtualNetworkGatewayNatRule
Hämtar en NatRule för virtuell nätverksgateway.
Syntax
Get-AzVirtualNetworkGatewayNatRule
-ResourceGroupName <String>
-ParentResourceName <String>
[-Name <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Get-AzVirtualNetworkGatewayNatRule
-ParentObject <PSVirtualNetworkGateway>
[-Name <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Get-AzVirtualNetworkGatewayNatRule
-ParentResourceId <String>
[-Name <String>]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Description
Get-AzVirtualNetworkGatewayNatRule cmdlet returnerar ett nat-regelobjekt för den virtuella nätverksgatewayen baserat på Namn och ParentResourceName.
Exempel
Exempel 1
Get-AzVirtualNetworkGatewayNatRule -ResourceGroupName "rg1" -Name "natRule1" -ParentResourceName gw1
Name : natRule1
ProvisioningState : Succeeded
Type : Static
Mode : IngressSnat
InternalMappings : [
{
"AddressSpace": "25.0.0.0/16"
}
]
ExternalMappings : [
{
"AddressSpace": "30.0.0.0/16"
}
]
IpConfigurationId :
Id : /subscriptions/7afd8f92-c220-4f53-886e-1df53a69afd4/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworkGateways/gw1/natRules/natRule1
Etag : W/"5150d788-e165-42ba-99c4-8138a545fce9"
Exempel 2:
Get-AzVirtualNetworkGatewayNatRule -ResourceGroupName "rg1" -ParentResourceName "gw1"
Name : natRule1
ProvisioningState : Succeeded
Type : Static
Mode : IngressSnat
InternalMappings : [
{
"AddressSpace": "25.0.0.0/16"
}
]
ExternalMappings : [
{
"AddressSpace": "30.0.0.0/16"
}
]
IpConfigurationId :
Id : /subscriptions/7afd8f92-c220-4f53-886e-1df53a69afd4/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworkGateways/gw1/natRules/natRule1
Etag : W/"5150d788-e165-42ba-99c4-8138a545fce9"
Name : natRule2
ProvisioningState : Succeeded
Type : Static
Mode : EgressSnat
InternalMappings : [
{
"AddressSpace": "20.0.0.0/16"
}
]
ExternalMappings : [
{
"AddressSpace": "50.0.0.0/16"
}
]
IpConfigurationId :
Id : /subscriptions/7afd8f92-c220-4f53-886e-1df53a69afd4/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworkGateways/gw1/natRules/natRule2
Etag : W/"5150d788-e165-42ba-99c4-8138a545fce9"
Parametrar
-DefaultProfile
Autentiseringsuppgifter, konto, klientorganisation och prenumeration som används för kommunikation med Azure.
Typ: | IAzureContextContainer |
Alias: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
Standardvärde: | None |
Obligatorisk: | False |
Godkänn pipeline-indata: | False |
Godkänn jokertecken: | False |
-Name
Resursnamnet.
Typ: | String |
Alias: | ResourceName, VirtualNetworkGatewayNatRuleName |
Position: | Named |
Standardvärde: | None |
Obligatorisk: | False |
Godkänn pipeline-indata: | False |
Godkänn jokertecken: | True |
-ParentObject
Den överordnade VirtualNetworkGateway för detta VirtualNetworkGatewayNatRule.
Typ: | PSVirtualNetworkGateway |
Alias: | ParentVirtualNetworkGateway, VirtualNetworkGateway |
Position: | Named |
Standardvärde: | None |
Obligatorisk: | True |
Godkänn pipeline-indata: | True |
Godkänn jokertecken: | False |
-ParentResourceId
Resurs-ID:t för den överordnade VirtualNetworkGateway för den här VirtualNetworkGatewayNatRule.
Typ: | String |
Alias: | ParentVirtualNetworkGatewayId, VirtualNetworkGatewayId |
Position: | Named |
Standardvärde: | None |
Obligatorisk: | True |
Godkänn pipeline-indata: | True |
Godkänn jokertecken: | False |
-ParentResourceName
Det överordnade resursnamnet.
Typ: | String |
Alias: | ParentVirtualNetworkGatewayName, VirtualNetworkGatewayName |
Position: | Named |
Standardvärde: | None |
Obligatorisk: | True |
Godkänn pipeline-indata: | False |
Godkänn jokertecken: | False |
-ResourceGroupName
Resursgruppens namn.
Typ: | String |
Position: | Named |
Standardvärde: | None |
Obligatorisk: | True |
Godkänn pipeline-indata: | False |
Godkänn jokertecken: | False |
Indata
Utdata
PSVirtualNetworkGatewayNatRule
Relaterade länkar
Azure PowerShell