Azure Recovery Services Network Mapping
This page shows how to write Terraform and Azure Resource Manager for Recovery Services Network Mapping and write them securely.
azurerm_site_recovery_network_mapping (Terraform)
The Network Mapping in Recovery Services can be configured in Terraform with the resource name azurerm_site_recovery_network_mapping
. The following sections describe 4 examples of how to use the resource and its parameters.
Example Usage from GitHub
resource "azurerm_site_recovery_network_mapping" "this" {
name = var.name
recovery_vault_name = var.recovery_vault_name
resource_group_name = var.resource_group_name
source_network_id = var.source_network_id
source_recovery_fabric_name = var.source_recovery_fabric_name
resource "azurerm_site_recovery_network_mapping" "this" {
name = var.name
recovery_vault_name = var.recovery_vault_name
resource_group_name = var.resource_group_name
source_network_id = var.source_network_id
source_recovery_fabric_name = var.source_recovery_fabric_name
resource "azurerm_site_recovery_network_mapping" "recovery-network-mapping" {
count = signum(var.create ? 1 : 0)
name = "recovery-network-mapping-secondary"
resource_group_name = var.resource_group_name
recovery_vault_name = azurerm_recovery_services_vault.vault.*.name[0]
source_recovery_fabric_name = azurerm_site_recovery_fabric.primary.*.name[0]
resource "azurerm_site_recovery_network_mapping" "recovery-network-mapping" {
count = signum(var.create ? 1 : 0)
name = "recovery-network-mapping-secondary"
resource_group_name = var.resource_group_name
recovery_vault_name = azurerm_recovery_services_vault.vault.*.name[0]
source_recovery_fabric_name = azurerm_site_recovery_fabric.primary.*.name[0]
Parameters
-
id
optional computed - string -
name
required - string -
recovery_vault_name
required - string -
resource_group_name
required - string -
source_network_id
required - string -
source_recovery_fabric_name
required - string -
target_network_id
required - string -
target_recovery_fabric_name
required - string -
timeouts
single block
Explanation in Terraform Registry
Manages a site recovery network mapping on Azure. A network mapping decides how to translate connected netwroks when a VM is migrated from one region to another.
Microsoft.RecoveryServices/vaults/replicationFabrics/replicationNetworks/replicationNetworkMappings (Azure Resource Manager)
The vaults/replicationFabrics/replicationNetworks/replicationNetworkMappings in Microsoft.RecoveryServices can be configured in Azure Resource Manager with the resource name Microsoft.RecoveryServices/vaults/replicationFabrics/replicationNetworks/replicationNetworkMappings
. The following sections describe how to use the resource and its parameters.
Example Usage from GitHub
An example could not be found in GitHub.
Frequently asked questions
What is Azure Recovery Services Network Mapping?
Azure Recovery Services Network Mapping is a resource for Recovery Services of Microsoft Azure. Settings can be wrote in Terraform.
Where can I find the example code for the Azure Recovery Services Network Mapping?
For Terraform, the kevinhead/azurerm, niveklabs/azurerm and rohrerb/terraform-eiac source code examples are useful. See the Terraform Example section for further details.