» azurerm_eventgrid_domain
Manages an EventGrid Domain
» Example Usage
resource "azurerm_resource_group" "test" {
name = "resourceGroup1"
location = "West US 2"
}
resource "azurerm_eventgrid_domain" "test" {
name = "my-eventgrid-domain"
location = "${azurerm_resource_group.test.location}"
resource_group_name = "${azurerm_resource_group.test.name}"
tags = {
environment = "Production"
}
}
» Argument Reference
The following arguments are supported:
-
name- (Required) Specifies the name of the EventGrid Domain resource. Changing this forces a new resource to be created. -
resource_group_name- (Required) The name of the resource group in which the EventGrid Domain exists. Changing this forces a new resource to be created. -
location- (Required) Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created. -
input_schema- (Optional) Specifies the schema in which incoming events will be published to this domain. Allowed values arecloudeventv01schema,customeventschema, oreventgridschema. Defaults toeventgridschema. Changing this forces a new resource to be created. -
input_mapping_fields- (Optional) Ainput_mapping_fieldsblock as defined below. -
input_mapping_default_values- (Optional) Ainput_mapping_default_valuesblock as defined below. -
tags- (Optional) A mapping of tags to assign to the resource.
A input_mapping_fields supports the following:
-
id- (Optional) Specifies the id of the EventGrid Event to associate with the domain. Changing this forces a new resource to be created. -
topic- (Optional) Specifies the topic of the EventGrid Event to associate with the domain. Changing this forces a new resource to be created. -
event_type- (Optional) Specifies the event type of the EventGrid Event to associate with the domain. Changing this forces a new resource to be created. -
event_time- (Optional) Specifies the event time of the EventGrid Event to associate with the domain. Changing this forces a new resource to be created. -
data_version- (Optional) Specifies the data version of the EventGrid Event to associate with the domain. Changing this forces a new resource to be created. -
subject- (Optional) Specifies the subject of the EventGrid Event to associate with the domain. Changing this forces a new resource to be created.
A input_mapping_default_values supports the following:
-
event_type- (Optional) Specifies the default event type of the EventGrid Event to associate with the domain. Changing this forces a new resource to be created. -
data_version- (Optional) Specifies the default data version of the EventGrid Event to associate with the domain. Changing this forces a new resource to be created. -
subject- (Optional) Specifies the default subject of the EventGrid Event to associate with the domain. Changing this forces a new resource to be created.
» Attributes Reference
The following attributes are exported:
» Import
EventGrid Domain's can be imported using the resource id, e.g.
terraform import azurerm_eventgrid_domain.domain1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.EventGrid/domains/domain1