Skip to content

Commit 16b9a73

Browse files
authored
Merge pull request #3 from VIOOH/fix/sgname
change names of resources
2 parents 220b997 + 9ac845b commit 16b9a73

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

main.tf

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ resource "random_id" "salt" {
77
}
88

99
resource "aws_elasticache_replication_group" "redis" {
10-
replication_group_id = format("%.20s", "${var.name}-${var.env}")
11-
replication_group_description = "Terraform-managed ElastiCache replication group for ${var.name}-${var.env}"
10+
replication_group_id = format("%.20s", "${var.name}")
11+
replication_group_description = "Terraform-managed ElastiCache replication group for ${var.name}"
1212
number_cache_clusters = var.redis_clusters
1313
node_type = var.redis_node_type
1414
automatic_failover_enabled = var.redis_failover
@@ -36,9 +36,9 @@ resource "aws_elasticache_replication_group" "redis" {
3636
resource "aws_elasticache_parameter_group" "redis_parameter_group" {
3737

3838
# tf-redis-sc-api-queue-dev
39-
name = "tf-redis-${var.name}-${var.env}"
39+
name = "tf-redis-${var.name}"
4040

41-
description = "Terraform-managed ElastiCache parameter group for ${var.name}-${var.env}"
41+
description = "Terraform-managed ElastiCache parameter group for ${var.name}"
4242

4343
# Strip the patch version from redis_version var
4444
family = "redis${replace(var.redis_version, "/\\.[\\d]+$/", "")}"
@@ -61,6 +61,6 @@ resource "aws_elasticache_parameter_group" "redis_parameter_group" {
6161
}
6262

6363
resource "aws_elasticache_subnet_group" "redis_subnet_group" {
64-
name = "tf-redis-${var.name}-${var.env}"
64+
name = "tf-redis-${var.name}"
6565
subnet_ids = var.subnets
6666
}

security_groups.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
resource "aws_security_group" "redis_security_group" {
2-
name = "tf-sg-ec-${var.name}-${var.env}"
3-
description = "Terraform-managed ElastiCache security group for ${var.name}-${var.env}"
2+
name = "tf-sg-ec-${var.name}"
3+
description = "Terraform-managed ElastiCache security group for ${var.name}"
44
vpc_id = data.aws_vpc.vpc.id
55

66
tags = {

0 commit comments

Comments
 (0)