cloudposse / terraform-aws-elasticsearch

Terraform module to provision an Elasticsearch cluster with built-in integrations with Kibana and Logstash.
https://cloudposse.com/accelerate
Apache License 2.0
216 stars 232 forks source link

Support `multi_az_with_standby_enabled` #195

Open lukehsiao opened 5 hours ago

lukehsiao commented 5 hours ago

Describe the Feature

I would like to use multi_az_with_standby_enabled for our opensearch cluster.

image

If I turn this on manually in AWS Console, then re-run terraform plan, I see the following.

Terraform used the selected providers to generate the following execution plan. Resource actions are indicated with the following symbols:
  ~ update in-place

Terraform will perform the following actions:

  # module.dev_cluster.module.elasticsearch.aws_opensearch_domain.default[0] will be updated in-place
  ~ resource "aws_opensearch_domain" "default" {
        id                 = "arn:aws:es:us-west-2:redacted-elasticsearch"
        tags               = {
            "Environment"  = "dev"
            "Name"         = "elasticsearch"
            "Namespace"    = "ns"
            "VantaNonProd" = "true"
        }
        # (10 unchanged attributes hidden)

      ~ cluster_config {
          - multi_az_with_standby_enabled = true -> null
            # (9 unchanged attributes hidden)

            # (2 unchanged blocks hidden)
        }

        # (11 unchanged blocks hidden)
    }

Plan: 0 to add, 1 to change, 0 to destroy.

Expected Behavior

There is a configuration option exposed that allows me to enable this setting.

Use Case

I want to follow AWS's recommended best practice.

Describe Ideal Solution

There is a configuration option exposed that allows me to enable this setting.

Alternatives Considered

No response

Additional Context

No response

lukehsiao commented 4 hours ago

I likely could provide a PR for this if this is something the cloudposse team would be interested in supporting.