p2s_vpn_gateways
Creates, updates, deletes, gets or lists a p2s_vpn_gateways resource.
Overview
| Name | p2s_vpn_gateways |
| Type | Resource |
| Id | azure.network.p2s_vpn_gateways |
Fields
The following fields are returned by SELECT queries:
- get
- list_by_resource_group
- list
| Name | Datatype | Description |
|---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
customDnsServers | array | List of all customer specified DNS servers IP addresses. |
etag | string | A unique read-only string that changes whenever the resource is updated. |
isRoutingPreferenceInternet | boolean | Enable Routing Preference property for the Public IP Interface of the P2SVpnGateway. |
location | string | Resource location. |
p2SConnectionConfigurations | array | List of all p2s connection configurations of the gateway. |
provisioningState | string | The provisioning state of the P2S VPN gateway resource. Known values are: "Failed", "Succeeded", "Canceled", "Creating", "Updating", and "Deleting". (Failed, Succeeded, Canceled, Creating, Updating, Deleting) |
tags | object | Resource tags. |
type | string | Resource type. |
virtualHub | object | Reference to another subresource. |
vpnClientConnectionHealth | object | All P2S VPN clients' connection health status. |
vpnGatewayScaleUnit | integer | The scale unit for this p2s vpn gateway. |
vpnServerConfiguration | object | Reference to another subresource. |
| Name | Datatype | Description |
|---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
customDnsServers | array | List of all customer specified DNS servers IP addresses. |
etag | string | A unique read-only string that changes whenever the resource is updated. |
isRoutingPreferenceInternet | boolean | Enable Routing Preference property for the Public IP Interface of the P2SVpnGateway. |
location | string | Resource location. |
p2SConnectionConfigurations | array | List of all p2s connection configurations of the gateway. |
provisioningState | string | The provisioning state of the P2S VPN gateway resource. Known values are: "Failed", "Succeeded", "Canceled", "Creating", "Updating", and "Deleting". (Failed, Succeeded, Canceled, Creating, Updating, Deleting) |
tags | object | Resource tags. |
type | string | Resource type. |
virtualHub | object | Reference to another subresource. |
vpnClientConnectionHealth | object | All P2S VPN clients' connection health status. |
vpnGatewayScaleUnit | integer | The scale unit for this p2s vpn gateway. |
vpnServerConfiguration | object | Reference to another subresource. |
| Name | Datatype | Description |
|---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
customDnsServers | array | List of all customer specified DNS servers IP addresses. |
etag | string | A unique read-only string that changes whenever the resource is updated. |
isRoutingPreferenceInternet | boolean | Enable Routing Preference property for the Public IP Interface of the P2SVpnGateway. |
location | string | Resource location. |
p2SConnectionConfigurations | array | List of all p2s connection configurations of the gateway. |
provisioningState | string | The provisioning state of the P2S VPN gateway resource. Known values are: "Failed", "Succeeded", "Canceled", "Creating", "Updating", and "Deleting". (Failed, Succeeded, Canceled, Creating, Updating, Deleting) |
tags | object | Resource tags. |
type | string | Resource type. |
virtualHub | object | Reference to another subresource. |
vpnClientConnectionHealth | object | All P2S VPN clients' connection health status. |
vpnGatewayScaleUnit | integer | The scale unit for this p2s vpn gateway. |
vpnServerConfiguration | object | Reference to another subresource. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | resource_group_name, gateway_name, subscription_id | Retrieves the details of a virtual wan p2s vpn gateway. | |
list_by_resource_group | select | resource_group_name, subscription_id | Lists all the P2SVpnGateways in a resource group. | |
list | select | subscription_id | Lists all the P2SVpnGateways in a subscription. | |
create_or_update | insert | resource_group_name, gateway_name, subscription_id | Creates a virtual wan p2s vpn gateway if it doesn't exist else updates the existing gateway. | |
update_tags | update | resource_group_name, gateway_name, subscription_id | Updates virtual wan p2s vpn gateway tags. | |
create_or_update | replace | resource_group_name, gateway_name, subscription_id | Creates a virtual wan p2s vpn gateway if it doesn't exist else updates the existing gateway. | |
delete | delete | resource_group_name, gateway_name, subscription_id | Deletes a virtual wan p2s vpn gateway. | |
get_p2s_vpn_connection_health | exec | resource_group_name, gateway_name, subscription_id | Gets the connection health of P2S clients of the virtual wan P2SVpnGateway in the specified resource group. | |
get_p2s_vpn_connection_health_detailed | exec | resource_group_name, gateway_name, subscription_id | Gets the sas url to get the connection health detail of P2S clients of the virtual wan P2SVpnGateway in the specified resource group. | |
reset | exec | resource_group_name, gateway_name, subscription_id | Resets the primary of the p2s vpn gateway in the specified resource group. | |
generate_vpn_profile | exec | resource_group_name, gateway_name, subscription_id | Generates VPN profile for P2S client of the P2SVpnGateway in the specified resource group. | |
disconnect_p2s_vpn_connections | exec | resource_group_name, p2s_vpn_gateway_name, subscription_id | Disconnect P2S vpn connections of the virtual wan P2SVpnGateway in the specified resource group. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
gateway_name | string | The name of the gateway. Required. |
p2s_vpn_gateway_name | string | The name of the P2S Vpn Gateway. Required. |
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
subscription_id | string |
SELECT examples
- get
- list_by_resource_group
- list
Retrieves the details of a virtual wan p2s vpn gateway.
SELECT
id,
name,
customDnsServers,
etag,
isRoutingPreferenceInternet,
location,
p2SConnectionConfigurations,
provisioningState,
tags,
type,
virtualHub,
vpnClientConnectionHealth,
vpnGatewayScaleUnit,
vpnServerConfiguration
FROM azure.network.p2s_vpn_gateways
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND gateway_name = '{{ gateway_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Lists all the P2SVpnGateways in a resource group.
SELECT
id,
name,
customDnsServers,
etag,
isRoutingPreferenceInternet,
location,
p2SConnectionConfigurations,
provisioningState,
tags,
type,
virtualHub,
vpnClientConnectionHealth,
vpnGatewayScaleUnit,
vpnServerConfiguration
FROM azure.network.p2s_vpn_gateways
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Lists all the P2SVpnGateways in a subscription.
SELECT
id,
name,
customDnsServers,
etag,
isRoutingPreferenceInternet,
location,
p2SConnectionConfigurations,
provisioningState,
tags,
type,
virtualHub,
vpnClientConnectionHealth,
vpnGatewayScaleUnit,
vpnServerConfiguration
FROM azure.network.p2s_vpn_gateways
WHERE subscription_id = '{{ subscription_id }}' -- required
;
INSERT examples
- create_or_update
- Manifest
Creates a virtual wan p2s vpn gateway if it doesn't exist else updates the existing gateway.
INSERT INTO azure.network.p2s_vpn_gateways (
id,
location,
tags,
properties,
resource_group_name,
gateway_name,
subscription_id
)
SELECT
'{{ id }}',
'{{ location }}',
'{{ tags }}',
'{{ properties }}',
'{{ resource_group_name }}',
'{{ gateway_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
etag,
location,
properties,
tags,
type
;
# Description fields are for documentation purposes
- name: p2s_vpn_gateways
props:
- name: resource_group_name
value: "{{ resource_group_name }}"
description: Required parameter for the p2s_vpn_gateways resource.
- name: gateway_name
value: "{{ gateway_name }}"
description: Required parameter for the p2s_vpn_gateways resource.
- name: subscription_id
value: "{{ subscription_id }}"
description: Required parameter for the p2s_vpn_gateways resource.
- name: id
value: "{{ id }}"
description: |
Resource ID.
- name: location
value: "{{ location }}"
description: |
Resource location.
- name: tags
value: "{{ tags }}"
description: |
Resource tags.
- name: properties
description: |
Properties of the P2SVpnGateway.
value:
virtualHub:
id: "{{ id }}"
p2SConnectionConfigurations:
- id: "{{ id }}"
properties:
vpnClientAddressPool:
addressPrefixes:
- "{{ addressPrefixes }}"
ipamPoolPrefixAllocations:
- pool:
id: "{{ id }}"
numberOfIpAddresses: "{{ numberOfIpAddresses }}"
allocatedAddressPrefixes: "{{ allocatedAddressPrefixes }}"
routingConfiguration:
associatedRouteTable:
id: "{{ id }}"
propagatedRouteTables:
labels: "{{ labels }}"
ids: "{{ ids }}"
vnetRoutes:
staticRoutesConfig: "{{ staticRoutesConfig }}"
staticRoutes: "{{ staticRoutes }}"
bgpConnections: "{{ bgpConnections }}"
inboundRouteMap:
id: "{{ id }}"
outboundRouteMap:
id: "{{ id }}"
enableInternetSecurity: {{ enableInternetSecurity }}
configurationPolicyGroupAssociations:
- id: "{{ id }}"
previousConfigurationPolicyGroupAssociations:
- id: "{{ id }}"
name: "{{ name }}"
type: "{{ type }}"
properties:
isDefault: {{ isDefault }}
priority: {{ priority }}
policyMembers: "{{ policyMembers }}"
p2SConnectionConfigurations: "{{ p2SConnectionConfigurations }}"
provisioningState: "{{ provisioningState }}"
etag: "{{ etag }}"
provisioningState: "{{ provisioningState }}"
name: "{{ name }}"
etag: "{{ etag }}"
provisioningState: "{{ provisioningState }}"
vpnGatewayScaleUnit: {{ vpnGatewayScaleUnit }}
vpnServerConfiguration:
id: "{{ id }}"
vpnClientConnectionHealth:
totalIngressBytesTransferred: {{ totalIngressBytesTransferred }}
totalEgressBytesTransferred: {{ totalEgressBytesTransferred }}
vpnClientConnectionsCount: {{ vpnClientConnectionsCount }}
allocatedIpAddresses:
- "{{ allocatedIpAddresses }}"
customDnsServers:
- "{{ customDnsServers }}"
isRoutingPreferenceInternet: {{ isRoutingPreferenceInternet }}
UPDATE examples
- update_tags
Updates virtual wan p2s vpn gateway tags.
UPDATE azure.network.p2s_vpn_gateways
SET
tags = '{{ tags }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND gateway_name = '{{ gateway_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
etag,
location,
properties,
tags,
type;
REPLACE examples
- create_or_update
Creates a virtual wan p2s vpn gateway if it doesn't exist else updates the existing gateway.
REPLACE azure.network.p2s_vpn_gateways
SET
id = '{{ id }}',
location = '{{ location }}',
tags = '{{ tags }}',
properties = '{{ properties }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND gateway_name = '{{ gateway_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
etag,
location,
properties,
tags,
type;
DELETE examples
- delete
Deletes a virtual wan p2s vpn gateway.
DELETE FROM azure.network.p2s_vpn_gateways
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND gateway_name = '{{ gateway_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;
Lifecycle Methods
- get_p2s_vpn_connection_health
- get_p2s_vpn_connection_health_detailed
- reset
- generate_vpn_profile
- disconnect_p2s_vpn_connections
Gets the connection health of P2S clients of the virtual wan P2SVpnGateway in the specified resource group.
EXEC azure.network.p2s_vpn_gateways.get_p2s_vpn_connection_health
@resource_group_name='{{ resource_group_name }}' --required,
@gateway_name='{{ gateway_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;
Gets the sas url to get the connection health detail of P2S clients of the virtual wan P2SVpnGateway in the specified resource group.
EXEC azure.network.p2s_vpn_gateways.get_p2s_vpn_connection_health_detailed
@resource_group_name='{{ resource_group_name }}' --required,
@gateway_name='{{ gateway_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"vpnUserNamesFilter": "{{ vpnUserNamesFilter }}",
"outputBlobSasUrl": "{{ outputBlobSasUrl }}"
}'
;
Resets the primary of the p2s vpn gateway in the specified resource group.
EXEC azure.network.p2s_vpn_gateways.reset
@resource_group_name='{{ resource_group_name }}' --required,
@gateway_name='{{ gateway_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;
Generates VPN profile for P2S client of the P2SVpnGateway in the specified resource group.
EXEC azure.network.p2s_vpn_gateways.generate_vpn_profile
@resource_group_name='{{ resource_group_name }}' --required,
@gateway_name='{{ gateway_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"authenticationMethod": "{{ authenticationMethod }}"
}'
;
Disconnect P2S vpn connections of the virtual wan P2SVpnGateway in the specified resource group.
EXEC azure.network.p2s_vpn_gateways.disconnect_p2s_vpn_connections
@resource_group_name='{{ resource_group_name }}' --required,
@p2s_vpn_gateway_name='{{ p2s_vpn_gateway_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"vpnConnectionIds": "{{ vpnConnectionIds }}"
}'
;