Manages an EventGrid Domain Topic
resource "azurerm_resource_group" "example" {
name = "example-resources"
location = "West Europe"
}
resource "azurerm_eventgrid_domain" "example" {
name = "my-eventgrid-domain"
location = azurerm_resource_group.example.location
resource_group_name = azurerm_resource_group.example.name
tags = {
environment = "Production"
}
}
resource "azurerm_eventgrid_domain_topic" "example" {
name = "my-eventgrid-domain-topic"
domain_name = azurerm_eventgrid_domain.example.name
resource_group_name = azurerm_resource_group.example.name
}
The following arguments are supported:
name
- (Required) Specifies the name of the EventGrid Domain Topic resource. Changing this forces a new resource to be created.
domain_name
- (Required) Specifies the name of the EventGrid Domain. 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.
In addition to the Arguments listed above - the following Attributes are exported:
id
- The ID of the EventGrid Domain Topic.The timeouts
block allows you to specify timeouts for certain actions:
create
- (Defaults to 30 minutes) Used when creating the EventGrid Domain Topic.update
- (Defaults to 30 minutes) Used when updating the EventGrid Domain Topic.read
- (Defaults to 5 minutes) Used when retrieving the EventGrid Domain Topic.delete
- (Defaults to 30 minutes) Used when deleting the EventGrid Domain Topic.EventGrid Domain Topics can be imported using the resource id
, e.g.
terraform import azurerm_eventgrid_domain_topic.topic1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.EventGrid/domains/domain1/topics/topic1