Skip to content

Commit

Permalink
Relax cluster setting regex (#79)
Browse files Browse the repository at this point in the history
Signed-off-by: Prudhvi Godithi <pgodithi@amazon.com>
  • Loading branch information
prudhvigodithi authored Sep 11, 2023
1 parent 1ad1fc8 commit 686367b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion provider/resource_opensearch_cluster_settings.go
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ func resourceOpensearchClusterSettings() *schema.Resource {
"action_auto_create_index": {
Type: schema.TypeString,
Optional: true,
ValidateFunc: validation.StringMatch(regexp.MustCompile(`^(true|false|([-+]?[a-z0-9][a-z0-9_-]*\*?,?)+)$`), "expected value to be one of: true, false or comma-separated list"),
ValidateFunc: validation.StringMatch(regexp.MustCompile(`^(true|false|([-+]?[a-z0-9_*.,]+)+)$`), "expected value to be one of: true, false or comma-separated list"),
Description: "Whether to automatically create an index if it doesn’t already exist and apply any configured index template",
},
"action_destructive_requires_name": {
Expand Down
2 changes: 1 addition & 1 deletion provider/resource_opensearch_cluster_settings_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,6 @@ func checkOpensearchClusterSettingsDestroy(s *terraform.State) error {
var testAccOpensearchClusterSettings = `
resource "opensearch_cluster_settings" "global" {
cluster_max_shards_per_node = 10
action_auto_create_index = "my-index-000001,index10,-index1*,+ind*"
action_auto_create_index = "my-index-000001,index10,-index1*,+ind*,-.aws_cold_catalog*,+*"
}
`

0 comments on commit 686367b

Please sign in to comment.