Azure Redis Enterprise Cluster

This page shows how to write Terraform and Azure Resource Manager for Redis Enterprise Cluster and write them securely.

azurerm_redis_enterprise_cluster (Terraform)

The Cluster in Redis Enterprise can be configured in Terraform with the resource name azurerm_redis_enterprise_cluster. The following sections describe 9 examples of how to use the resource and its parameters.

Example Usage from GitHub

azurerm_redis_enterprise_cluster.tf#L1
resource "azurerm_redis_enterprise_cluster" "primary" {
  name                = format("redisgeek-%s", random_string.acre_primary_name.result)
  resource_group_name = azurerm_resource_group.resource_group.name
  location            = random_shuffle.regions-with-az.result[0]
  zones               = [1, 2, 3]
  sku_name            = var.acre_sku
re.tf#L9
resource "azurerm_redis_enterprise_cluster" "abhi-re-1" {
  name                = "abhi-re-1"
  resource_group_name = local.resource_grp_name
  location            = local.location_0
  sku_name            = "Enterprise_E20-2"
  zones               = [2]
main.tf#L6
resource "azurerm_redis_enterprise_cluster" "redis-enterprise" {
  name                = var.name
  resource_group_name = data.azurerm_resource_group.redis-enterprise.name
  location            = data.azurerm_resource_group.redis-enterprise.location
  sku_name            = var.sku_name
}
azurerm_redis_enterprise_cluster.tf#L1
resource "azurerm_redis_enterprise_cluster" "redislabs" {
  name                = format("redislabs-%s", random_string.redis_enterprise_name.result)
  resource_group_name = azurerm_resource_group.redislabs.name
  location            = azurerm_resource_group.redislabs.location
  zones               = [1,2,3]
  sku_name = var.acre_sku
azurerm_redis_enterprise_cluster.tf#L1
resource "azurerm_redis_enterprise_cluster" "redisgeek" {
  name                = format("redisgeek-%s", random_string.redis_enterprise_name.result)
  resource_group_name = azurerm_resource_group.redisgeek.name
  location            = azurerm_resource_group.redisgeek.location
  zones               = [1, 2, 3]
  sku_name            = var.acre_sku
azurerm_redis_enterprise_cluster.tf#L1
resource "azurerm_redis_enterprise_cluster" "redisgeek" {
  name                = format("redisgeek-%s", random_string.redis_enterprise_name.result)
  resource_group_name = azurerm_resource_group.redisgeek.name
  location            = azurerm_resource_group.redisgeek.location
  zones               = [1, 2, 3]
  sku_name            = var.acre_sku
azurerm_redis_enterprise_cluster.tf#L1
resource "azurerm_redis_enterprise_cluster" "redisgeek" {
  name                = format("acrf-%s", var.random_id)
  resource_group_name = data.azurerm_resource_group.redisgeek.name
  location            = data.azurerm_resource_group.redisgeek.location
  sku_name            = var.acre_sku
  tags                = data.azurerm_resource_group.redisgeek.tags
azurerm_redis_enterprise_cluster.tf#L1
resource "azurerm_redis_enterprise_cluster" "redisgeek" {
  name                = format("acre-%s", var.random_id)
  resource_group_name = data.azurerm_resource_group.redisgeek.name
  location            = data.azurerm_resource_group.redisgeek.location
  sku_name            = var.acre_sku
  tags                = data.azurerm_resource_group.redisgeek.tags
azurerm_redis_enterprise_cluster.tf#L1
resource "azurerm_redis_enterprise_cluster" "redisgeek" {
  name                = format("redisgeek-%s", random_string.redis_enterprise_name.result)
  resource_group_name = azurerm_resource_group.redisgeek.name
  location            = var.location
  zones               = [1, 2, 3]
  sku_name            = var.acre_sku

Review your Terraform file for Azure best practices

Shisho Cloud, our free checker to make sure your Terraform configuration follows best practices, is available (beta).

Parameters

Explanation in Terraform Registry

Manages a Redis Enterprise Cluster.

Microsoft.Cache/redisEnterprise (Azure Resource Manager)

The redisEnterprise in Microsoft.Cache can be configured in Azure Resource Manager with the resource name Microsoft.Cache/redisEnterprise. The following sections describe how to use the resource and its parameters.

Example Usage from GitHub

cluster.json#L8
            "type": "Microsoft.Cache/redisEnterprise",
            "apiVersion": "2021-02-01-preview",
            "properties": {},
            "location": "${location}",
            "dependsOn": [],
            "sku": {
acre-standalone.json#L8
      "type": "Microsoft.Cache/redisEnterprise",
      "apiVersion": "2021-03-01",
      "properties": {},
      "location": "${location}",
      "dependsOn": [],
      "sku": {
re1.json#L7
            "type": "Microsoft.Cache/redisEnterprise",
            "apiVersion": "2021-02-01-preview",
            "name": "${re_name}",
            "location": "${location}",
            "dependsOn": [],
            "tags": {
acre-crdb.json#L8
      "type": "Microsoft.Cache/redisEnterprise",
      "apiVersion": "2021-03-01",
      "properties": {},
      "location": "${location}",
      "dependsOn": [],
      "sku": {
easy-button-alerts.json#L69
            "type": "Microsoft.Cache/redisEnterprise",
            "apiVersion": "2020-10-01-preview",
            "name": "[variables('redis_enterprise_name')]",
            "location": "[variables('location')]",
            "tags": "[parameters('resourceTags')]",
            "sku": {
deployment.json#L138
      "type": "Microsoft.Cache/redisEnterprise",
      "apiVersion": "2021-02-01-preview",
      "properties": {},
      "location": "[parameters('Region1')]",
      "dependsOn": [],
      "sku": {
re2.json#L7
            "type": "Microsoft.Cache/redisEnterprise",
            "apiVersion": "2021-02-01-preview",
            "name": "${re_name_2}",
            "location": "${location}",
            "dependsOn": [],
            "tags": {
re1.json#L7
            "type": "Microsoft.Cache/redisEnterprise",
            "apiVersion": "2021-02-01-preview",
            "name": "${re_name}",
            "location": "${location}",
            "dependsOn": [],
            "tags": {
easy-button-geo.json#L138
        "type": "Microsoft.Cache/redisEnterprise",
        "apiVersion": "2021-02-01-preview",
        "properties": {},
        "location": "[parameters('Region1')]",
        "dependsOn": [],
        "sku": {
deployment.json#L138
      "type": "Microsoft.Cache/redisEnterprise",
      "apiVersion": "2021-02-01-preview",
      "properties": {},
      "location": "[parameters('Region1')]",
      "dependsOn": [],
      "sku": {

Frequently asked questions

What is Azure Redis Enterprise Cluster?

Azure Redis Enterprise Cluster is a resource for Redis Enterprise of Microsoft Azure. Settings can be wrote in Terraform.

Where can I find the example code for the Azure Redis Enterprise Cluster?

For Terraform, the redisgeek/acre-terraform-cron-replication, bestarch/re and rafaelvelosoAZ/NewOne source code examples are useful. See the Terraform Example section for further details.

For Azure Resource Manager, the Redislabs-Solution-Architects/acre-terraform-geo-replication-simple, Redislabs-Solution-Architects/acre-arm and bestarch/re-aa source code examples are useful. See the Azure Resource Manager Example section for further details.