zones
Creates, updates, deletes, gets or lists a zones
resource.
Overview
Name | zones |
Type | Resource |
Id | azure.dns.zones |
Fields
- vw_zones
- zones
Name | Datatype | Description |
---|---|---|
id | text | Resource ID. |
name | text | Resource name. |
etag | text | The etag of the zone. |
location | text | Resource location. |
max_number_of_record_sets | text | field from the properties object |
max_number_of_records_per_record_set | text | field from the properties object |
name_servers | text | field from the properties object |
number_of_record_sets | text | field from the properties object |
registration_virtual_networks | text | field from the properties object |
resolution_virtual_networks | text | field from the properties object |
resourceGroupName | text | field from the properties object |
signing_keys | text | field from the properties object |
subscriptionId | text | field from the properties object |
system_data | text | field from the properties object |
tags | text | Resource tags. |
type | text | Resource type. |
zoneName | text | field from the properties object |
zone_type | text | field from the properties object |
Name | Datatype | Description |
---|---|---|
id | string | Resource ID. |
name | string | Resource name. |
etag | string | The etag of the zone. |
location | string | Resource location. |
properties | object | Represents the properties of the zone. |
systemData | object | Metadata pertaining to creation and last modification of the resource. |
tags | object | Resource tags. |
type | string | Resource type. |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | resourceGroupName, subscriptionId, zoneName | Gets a DNS zone. Retrieves the zone properties, but not the record sets within the zone. |
list | SELECT | subscriptionId | Lists the DNS zones in all resource groups in a subscription. |
list_by_resource_group | SELECT | resourceGroupName, subscriptionId | Lists the DNS zones within a resource group. |
create_or_update | INSERT | resourceGroupName, subscriptionId, zoneName | Creates or updates a DNS zone. Does not modify DNS records within the zone. |
delete | DELETE | resourceGroupName, subscriptionId, zoneName | Deletes a DNS zone. WARNING: All DNS records in the zone will also be deleted. This operation cannot be undone. |
update | UPDATE | resourceGroupName, subscriptionId, zoneName | Updates a DNS zone. Does not modify DNS records within the zone. |
SELECT
examples
Lists the DNS zones in all resource groups in a subscription.
- vw_zones
- zones
SELECT
id,
name,
etag,
location,
max_number_of_record_sets,
max_number_of_records_per_record_set,
name_servers,
number_of_record_sets,
registration_virtual_networks,
resolution_virtual_networks,
resourceGroupName,
signing_keys,
subscriptionId,
system_data,
tags,
type,
zoneName,
zone_type
FROM azure.dns.vw_zones
WHERE subscriptionId = '{{ subscriptionId }}';
SELECT
id,
name,
etag,
location,
properties,
systemData,
tags,
type
FROM azure.dns.zones
WHERE subscriptionId = '{{ subscriptionId }}';
INSERT
example
Use the following StackQL query and manifest file to create a new zones
resource.
- All Properties
- Manifest
/*+ create */
INSERT INTO azure.dns.zones (
resourceGroupName,
subscriptionId,
zoneName,
etag,
properties,
location,
tags
)
SELECT
'{{ resourceGroupName }}',
'{{ subscriptionId }}',
'{{ zoneName }}',
'{{ etag }}',
'{{ properties }}',
'{{ location }}',
'{{ tags }}'
;
- name: your_resource_model_name
props:
- name: etag
value: string
- name: properties
value:
- name: maxNumberOfRecordSets
value: integer
- name: maxNumberOfRecordsPerRecordSet
value: integer
- name: numberOfRecordSets
value: integer
- name: nameServers
value:
- string
- name: zoneType
value: string
- name: registrationVirtualNetworks
value:
- - name: id
value: string
- name: resolutionVirtualNetworks
value:
- - name: id
value: string
- name: signingKeys
value:
- - name: delegationSignerInfo
value:
- - name: digestAlgorithmType
value: []
- name: digestValue
value: string
- name: record
value: string
- name: flags
value: integer
- name: keyTag
value: integer
- name: protocol
value: integer
- name: publicKey
value: string
- name: securityAlgorithmType
value: []
- name: systemData
value:
- name: createdBy
value: string
- name: createdByType
value: string
- name: createdAt
value: string
- name: lastModifiedBy
value: string
- name: lastModifiedByType
value: string
- name: lastModifiedAt
value: string
- name: id
value: string
- name: name
value: string
- name: type
value: string
- name: location
value: string
- name: tags
value: object
UPDATE
example
Updates a zones
resource.
/*+ update */
UPDATE azure.dns.zones
SET
tags = '{{ tags }}'
WHERE
resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND zoneName = '{{ zoneName }}';
DELETE
example
Deletes the specified zones
resource.
/*+ delete */
DELETE FROM azure.dns.zones
WHERE resourceGroupName = '{{ resourceGroupName }}'
AND subscriptionId = '{{ subscriptionId }}'
AND zoneName = '{{ zoneName }}';