afd_profiles
Creates, updates, deletes, gets or lists an afd_profiles resource.
Overview
| Name | afd_profiles |
| Type | Resource |
| Id | azure.cdn.afd_profiles |
Fields
The following fields are returned by SELECT queries:
- check_endpoint_name_availability
- check_host_name_availability
- list_resource_usage
| Name | Datatype | Description |
|---|---|---|
availableHostname | string | Returns the available hostname generated based on the AutoGeneratedDomainNameLabelScope when the name is available, otherwise it returns empty string. |
message | string | The detailed error message describing why the name is not available. |
nameAvailable | boolean | Indicates whether the name is available. |
reason | string | The reason why the name is not available. |
| Name | Datatype | Description |
|---|---|---|
message | string | The detailed error message describing why the name is not available. |
nameAvailable | boolean | Indicates whether the name is available. |
reason | string | The reason why the name is not available. |
| Name | Datatype | Description |
|---|---|---|
id | string | Resource identifier. |
name | object | The name of the type of usage. Required. |
currentValue | integer | The current value of the usage. Required. |
limit | integer | The limit of usage. Required. |
unit | string | An enum describing the unit of measurement. Required. "Count" (Count) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
check_endpoint_name_availability | select | resource_group_name, profile_name, subscription_id | Check the availability of an afdx endpoint name, and return the globally unique endpoint host name. | |
check_host_name_availability | select | resource_group_name, profile_name, subscription_id | Validates the custom domain mapping to ensure it maps to the correct Azure Front Door endpoint in DNS. | |
list_resource_usage | select | resource_group_name, profile_name, subscription_id | Checks the quota and actual usage of endpoints under the given Azure Front Door profile. | |
validate_secret | exec | resource_group_name, profile_name, subscription_id, secretType, secretSource | Validate a Secret in the profile. | |
upgrade | exec | resource_group_name, profile_name, subscription_id, wafMappingList | Upgrade a profile from Standard_AzureFrontDoor to Premium_AzureFrontDoor. |
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 |
|---|---|---|
profile_name | string | Name of the Azure Front Door Standard or Azure Front Door Premium or CDN profile which is unique within the resource group. Required. |
resource_group_name | string | The name of the resource group. The name is case insensitive. Required. |
subscription_id | string |
SELECT examples
- check_endpoint_name_availability
- check_host_name_availability
- list_resource_usage
Check the availability of an afdx endpoint name, and return the globally unique endpoint host name.
SELECT
availableHostname,
message,
nameAvailable,
reason
FROM azure.cdn.afd_profiles
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND profile_name = '{{ profile_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Validates the custom domain mapping to ensure it maps to the correct Azure Front Door endpoint in DNS.
SELECT
message,
nameAvailable,
reason
FROM azure.cdn.afd_profiles
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND profile_name = '{{ profile_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Checks the quota and actual usage of endpoints under the given Azure Front Door profile.
SELECT
id,
name,
currentValue,
limit,
unit
FROM azure.cdn.afd_profiles
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND profile_name = '{{ profile_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;
Lifecycle Methods
- validate_secret
- upgrade
Validate a Secret in the profile.
EXEC azure.cdn.afd_profiles.validate_secret
@resource_group_name='{{ resource_group_name }}' --required,
@profile_name='{{ profile_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"secretType": "{{ secretType }}",
"secretSource": "{{ secretSource }}",
"secretVersion": "{{ secretVersion }}"
}'
;
Upgrade a profile from Standard_AzureFrontDoor to Premium_AzureFrontDoor.
EXEC azure.cdn.afd_profiles.upgrade
@resource_group_name='{{ resource_group_name }}' --required,
@profile_name='{{ profile_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
@@json=
'{
"wafMappingList": "{{ wafMappingList }}"
}'
;