azurerm_digital_twins_endpoint_servicebus

Manages a Digital Twins Service Bus Endpoint.

Example Usage

provider "azurerm" {
  features {}
}

resource "azurerm_resource_group" "example" {
  name     = "example_resources"
  location = "West Europe"
}

resource "azurerm_digital_twins_instance" "example" {
  name                = "example-DT"
  resource_group_name = azurerm_resource_group.example.name
  location            = azurerm_resource_group.example.location
}

resource "azurerm_servicebus_namespace" "example" {
  name                = "exampleservicebusnamespace"
  location            = azurerm_resource_group.example.location
  resource_group_name = azurerm_resource_group.example.name
  sku                 = "Standard"
}

resource "azurerm_servicebus_topic" "example" {
  name         = "exampleservicebustopic"
  namespace_id = azurerm_servicebus_namespace.example.id
}

resource "azurerm_servicebus_topic_authorization_rule" "example" {
  name     = "example-rule"
  topic_id = azurerm_servicebus_topic.example.id

  listen = false
  send   = true
  manage = false
}

resource "azurerm_digital_twins_endpoint_servicebus" "example" {
  name                                   = "example-EndpointSB"
  digital_twins_id                       = azurerm_digital_twins_instance.example.id
  servicebus_primary_connection_string   = azurerm_servicebus_topic_authorization_rule.example.primary_connection_string
  servicebus_secondary_connection_string = azurerm_servicebus_topic_authorization_rule.example.secondary_connection_string
}

Arguments Reference

The following arguments are supported:

Attributes Reference

In addition to the Arguments listed above - the following Attributes are exported:

Timeouts

The timeouts block allows you to specify timeouts for certain actions:

Import

Digital Twins Service Bus Endpoints can be imported using the resource id, e.g.

terraform import azurerm_digital_twins_endpoint_servicebus.example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.DigitalTwins/digitalTwinsInstances/dt1/endpoints/ep1