Skip to content

Commit

Permalink
bugfix: import existing replication groups (#217)
Browse files Browse the repository at this point in the history
  • Loading branch information
y3ti authored Dec 21, 2023
1 parent 8eb5183 commit b7c841a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,15 @@ resource "aws_elasticache_replication_group" "default" {
replicas_per_node_group = var.cluster_mode_enabled ? var.cluster_mode_replicas_per_node_group : null
user_group_ids = var.user_group_ids

# When importing an aws_elasticache_replication_group resource the attribute
# security_group_names is imported as null. More details:
# https://github.com/hashicorp/terraform-provider-aws/issues/32835
lifecycle {
ignore_changes = [
security_group_names,
]
}

depends_on = [
aws_elasticache_parameter_group.default
]
Expand Down

0 comments on commit b7c841a

Please sign in to comment.