Skip to content

Commit 9bca2cd

Browse files
authored
feat: support multi_az_with_standby_enabled for opensearch (#196)
Note that this bumps the minimum `hashicorp/aws` provider version to 5.15.0, where this parameter was introduced [[1]]. The README diff was generated with `make init` and `make readme`, and introduces some minor unrelated changes. [1]: https://github.com/hashicorp/terraform-provider-aws/blob/main/CHANGELOG.md#5150-august-31-2023 Closes: #195
1 parent adfe5f6 commit 9bca2cd

File tree

4 files changed

+20
-12
lines changed

4 files changed

+20
-12
lines changed

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,13 +119,13 @@ Here are automated tests for the complete example using [bats](https://github.co
119119
| Name | Version |
120120
|------|---------|
121121
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.3 |
122-
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 5.0 |
122+
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 5.15.0 |
123123

124124
## Providers
125125

126126
| Name | Version |
127127
|------|---------|
128-
| <a name="provider_aws"></a> [aws](#provider\_aws) | >= 5.0 |
128+
| <a name="provider_aws"></a> [aws](#provider\_aws) | >= 5.15.0 |
129129

130130
## Modules
131131

@@ -230,6 +230,7 @@ Here are automated tests for the complete example using [bats](https://github.co
230230
| <a name="input_log_publishing_index_enabled"></a> [log\_publishing\_index\_enabled](#input\_log\_publishing\_index\_enabled) | Specifies whether log publishing option for INDEX\_SLOW\_LOGS is enabled or not | `bool` | `false` | no |
231231
| <a name="input_log_publishing_search_cloudwatch_log_group_arn"></a> [log\_publishing\_search\_cloudwatch\_log\_group\_arn](#input\_log\_publishing\_search\_cloudwatch\_log\_group\_arn) | ARN of the CloudWatch log group to which log for SEARCH\_SLOW\_LOGS needs to be published | `string` | `""` | no |
232232
| <a name="input_log_publishing_search_enabled"></a> [log\_publishing\_search\_enabled](#input\_log\_publishing\_search\_enabled) | Specifies whether log publishing option for SEARCH\_SLOW\_LOGS is enabled or not | `bool` | `false` | no |
233+
| <a name="input_multi_az_with_standby_enabled"></a> [multi\_az\_with\_standby\_enabled](#input\_multi\_az\_with\_standby\_enabled) | Enable domain with standby for OpenSearch cluster | `bool` | `false` | no |
233234
| <a name="input_name"></a> [name](#input\_name) | ID element. Usually the component or solution name, e.g. 'app' or 'jenkins'.<br/>This is the only ID element not also included as a `tag`.<br/>The "name" tag is set to the full `id` string. There is no tag with the value of the `name` input. | `string` | `null` | no |
234235
| <a name="input_namespace"></a> [namespace](#input\_namespace) | ID element. Usually an abbreviation of your organization name, e.g. 'eg' or 'cp', to help ensure generated IDs are globally unique | `string` | `null` | no |
235236
| <a name="input_node_to_node_encryption_enabled"></a> [node\_to\_node\_encryption\_enabled](#input\_node\_to\_node\_encryption\_enabled) | Whether to enable node-to-node encryption | `bool` | `false` | no |

opensearch_domain.tf

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -47,15 +47,16 @@ resource "aws_opensearch_domain" "default" {
4747
}
4848

4949
cluster_config {
50-
instance_count = var.instance_count
51-
instance_type = var.instance_type
52-
dedicated_master_enabled = var.dedicated_master_enabled
53-
dedicated_master_count = var.dedicated_master_count
54-
dedicated_master_type = var.dedicated_master_type
55-
zone_awareness_enabled = var.zone_awareness_enabled
56-
warm_enabled = var.warm_enabled
57-
warm_count = var.warm_enabled ? var.warm_count : null
58-
warm_type = var.warm_enabled ? var.warm_type : null
50+
instance_count = var.instance_count
51+
instance_type = var.instance_type
52+
dedicated_master_enabled = var.dedicated_master_enabled
53+
dedicated_master_count = var.dedicated_master_count
54+
dedicated_master_type = var.dedicated_master_type
55+
multi_az_with_standby_enabled = var.multi_az_with_standby_enabled
56+
zone_awareness_enabled = var.zone_awareness_enabled
57+
warm_enabled = var.warm_enabled
58+
warm_count = var.warm_enabled ? var.warm_count : null
59+
warm_type = var.warm_enabled ? var.warm_type : null
5960

6061
dynamic "zone_awareness_config" {
6162
for_each = var.availability_zone_count > 1 && var.zone_awareness_enabled ? [true] : []

variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,12 @@ variable "availability_zone_count" {
141141
}
142142
}
143143

144+
variable "multi_az_with_standby_enabled" {
145+
type = bool
146+
default = false
147+
description = "Enable domain with standby for OpenSearch cluster"
148+
}
149+
144150
variable "ebs_volume_size" {
145151
type = number
146152
description = "EBS volumes for data storage in GB"

versions.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ terraform {
44
required_providers {
55
aws = {
66
source = "hashicorp/aws"
7-
version = ">= 5.0"
7+
version = ">= 5.15.0"
88
}
99
}
1010
}

0 commit comments

Comments
 (0)