Azure Messaging Namespace Authorization Rule
This page shows how to write Terraform and Azure Resource Manager for Messaging Namespace Authorization Rule and write them securely.
azurerm_eventhub_namespace_authorization_rule (Terraform)
The Namespace Authorization Rule in Messaging can be configured in Terraform with the resource name azurerm_eventhub_namespace_authorization_rule. The following sections describe 10 examples of how to use the resource and its parameters.
Example Usage from GitHub
resource "azurerm_eventhub_namespace_authorization_rule" "authorization_rule" {
name = var.authorization_rule_name
namespace_name = var.event_hub_namespace
resource_group_name = var.resource_group_name
listen = true
send = true
resource "azurerm_eventhub_namespace_authorization_rule" "view_auth_rule" {
depends_on = [azurerm_eventhub_namespace.eventhubs, azurerm_eventhub.topic]
name = "view"
namespace_name = azurerm_eventhub_namespace.eventhubs.name
resource_group_name = azurerm_eventhub_namespace.eventhubs.resource_group_name
resource "azurerm_eventhub_namespace_authorization_rule" "evh_ns_rule" {
name = azurecaf_name.evh_ns_rule_name.result
namespace_name = var.namespace_name
resource_group_name = var.resource_group_name
listen = var.settings.listen
send = var.settings.send
resource "azurerm_eventhub_namespace_authorization_rule" "evh_ns_rule" {
name = var.settings.rule_name
namespace_name = var.namespace_name
resource_group_name = var.resource_group_name
listen = var.settings.listen
send = var.settings.send
resource "azurerm_eventhub_namespace_authorization_rule" "evh_ns_rule" {
name = azurecaf_name.evh_ns_rule_name.result
namespace_name = var.namespace_name
resource_group_name = var.resource_group_name
listen = var.settings.listen
send = var.settings.send
resource "azurerm_eventhub_namespace_authorization_rule" "evh_ns_rule" {
name = azurecaf_name.evh_ns_rule_name.result
namespace_name = var.namespace_name
resource_group_name = var.resource_group_name
listen = var.settings.listen
send = var.settings.send
resource "azurerm_eventhub_namespace_authorization_rule" "this" {
listen = var.listen
manage = var.manage
name = var.name
namespace_name = var.namespace_name
resource_group_name = var.resource_group_name
resource "azurerm_eventhub_namespace_authorization_rule" "eventhub_rule" {
name = var.eventhub_rule_name
namespace_name = azurerm_eventhub_namespace.eventhub_ns.name
resource_group_name = var.resource_group_name
listen = local.listen
resource "azurerm_eventhub_namespace_authorization_rule" "eventhub_ns_az_rule" {
count = var.create_eventhub_ns_authorization_rule ? 1 : 0
name = var.eventhub_authorization_rule_name
namespace_name = azurerm_eventhub_namespace.event_hub_namespace.name
resource_group_name = var.resource_group_name
listen = var.eventhub_ns_authorization_rule_listen
resource "azurerm_eventhub_namespace_authorization_rule" "this" {
listen = var.listen
manage = var.manage
name = var.name
namespace_name = var.namespace_name
resource_group_name = var.resource_group_name
Parameters
-
idoptional computed - string -
listenoptional - bool -
manageoptional - bool -
namerequired - string -
namespace_namerequired - string -
primary_connection_stringoptional computed - string -
primary_connection_string_aliasoptional computed - string -
primary_keyoptional computed - string -
resource_group_namerequired - string -
secondary_connection_stringoptional computed - string -
secondary_connection_string_aliasoptional computed - string -
secondary_keyoptional computed - string -
sendoptional - bool -
timeoutssingle block
Explanation in Terraform Registry
Manages an Authorization Rule for an Event Hub Namespace.
Microsoft.EventHub/namespaces/authorizationRules (Azure Resource Manager)
The namespaces/authorizationRules in Microsoft.EventHub can be configured in Azure Resource Manager with the resource name Microsoft.EventHub/namespaces/authorizationRules. The following sections describe how to use the resource and its parameters.
Example Usage from GitHub
An example could not be found in GitHub.
Parameters
apiVersionrequired - stringnamerequired - stringThe authorization rule name.
propertiesrequiredrightsrequired - arrayThe rights associated with the rule.
typerequired - string
Frequently asked questions
What is Azure Messaging Namespace Authorization Rule?
Azure Messaging Namespace Authorization Rule is a resource for Messaging of Microsoft Azure. Settings can be wrote in Terraform.
Where can I find the example code for the Azure Messaging Namespace Authorization Rule?
For Terraform, the prashant101386/devops, chesapeaketechnology/data-science and aztfmod/terraform-azurerm-caf source code examples are useful. See the Terraform Example section for further details.