nat_gateways
Creates, updates, deletes, gets or lists a nat_gateways
resource.
Overview
Name | nat_gateways |
Type | Resource |
Id | azure.network.nat_gateways |
Fields
- vw_nat_gateways
- nat_gateways
Name | Datatype | Description |
---|---|---|
id | text | Resource ID. |
name | text | Resource name. |
etag | text | A unique read-only string that changes whenever the resource is updated. |
idle_timeout_in_minutes | text | field from the properties object |
location | text | Resource location. |
natGatewayName | text | field from the properties object |
provisioning_state | text | field from the properties object |
public_ip_addresses | text | field from the properties object |
public_ip_prefixes | text | field from the properties object |
resourceGroupName | text | field from the properties object |
resource_guid | text | field from the properties object |
sku | text | SKU of nat gateway. |
subnets | text | field from the properties object |
subscriptionId | text | field from the properties object |
tags | text | Resource tags. |
type | text | Resource type. |
zones | text | A list of availability zones denoting the zone in which Nat Gateway should be deployed. |
Name | Datatype | Description |
---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
etag | string | A unique read-only string that changes whenever the resource is updated. |
location | string | Resource location. |
properties | object | Nat Gateway properties. |
sku | object | SKU of nat gateway. |
tags | object | Resource tags. |
type | string | Resource type. |
zones | array | A list of availability zones denoting the zone in which Nat Gateway should be deployed. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | natGatewayName, resourceGroupName, subscriptionId | Gets the specified nat gateway in a specified resource group. |
list | SELECT | resourceGroupName, subscriptionId | Gets all nat gateways in a resource group. |
list_all | SELECT | subscriptionId | Gets all the Nat Gateways in a subscription. |
create_or_update | INSERT | natGatewayName, resourceGroupName, subscriptionId | Creates or updates a nat gateway. |
delete | DELETE | natGatewayName, resourceGroupName, subscriptionId | Deletes the specified nat gateway. |
update_tags | EXEC | natGatewayName, resourceGroupName, subscriptionId | Updates nat gateway tags. |
SELECT
examples
Gets all the Nat Gateways in a subscription.
- vw_nat_gateways
- nat_gateways
SELECT
id,
name,
etag,
idle_timeout_in_minutes,
location,
natGatewayName,
provisioning_state,
public_ip_addresses,
public_ip_prefixes,
resourceGroupName,
resource_guid,
sku,
subnets,
subscriptionId,
tags,
type,
zones
FROM azure.network.vw_nat_gateways
WHERE subscriptionId = '{{ subscriptionId }}';
SELECT
id,
name,
etag,
location,
properties,
sku,
tags,
type,
zones
FROM azure.network.nat_gateways
WHERE subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new nat_gateways
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.network.nat_gateways (
natGatewayName,
resourceGroupName,
subscriptionId,
sku,
properties,
zones,
id,
location,
tags
)
SELECT
'{{ natGatewayName }}',
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ sku }}',
'{{ properties }}',
'{{ zones }}',
'{{ id }}',
'{{ location }}',
'{{ tags }}'
;
- name: your_resource_model_name
props:
- name: sku
value:
- name: name
value: string
- name: properties
value:
- name: idleTimeoutInMinutes
value: integer
- name: publicIpAddresses
value:
- - name: id
value: string
- name: publicIpPrefixes
value:
- - name: id
value: string
- name: subnets
value:
- - name: id
value: string
- name: resourceGuid
value: string
- name: provisioningState
value: []
- name: zones
value:
- string
- name: etag
value: string
- name: id
value: string
- name: name
value: string
- name: type
value: string
- name: location
value: string
- name: tags
value: object
DELETE
example
Deletes the specified nat_gateways
resource.
/*+ delete */
DELETE FROM azure.network.nat_gateways
WHERE natGatewayName = '{{ natGatewayName }}'
AND resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}';