Add support for shared VPC ingress shared security group rules
Closed this issue · 2 comments
mikeatlas commented
Hi uMotif,
Thanks for sharing this module. My redis cluster needs Shared VPC ingress security group support, and as such, the input variable security_group_ids
is not able to reference the existing SG in the shared VPC. Instead, I had to reference some outputs and create the ingress rules myself. Perhaps this could be integrated into future versions of your module:
resource "aws_security_group_rule" "shared_ingress" {
count = length(var.security_group_ids)
description = "From allowed SGs"
type = "ingress"
to_port = module.elasticache_redis.elasticache_port
from_port = module.elasticache_redis.elasticache_port
protocol = "tcp"
source_security_group_id = element(var.security_group_ids, count.index)
security_group_id = module.elasticache_redis.security_group_id
}
This specifically has source_security_group_id
input, which can support shared security group ingress source traffic.
Thanks!
Ohid25 commented
Thanks for the contribution @mikeatlas 🙌 ! This request has now been fulfilled and included in the 3.1.0 release.
mikeatlas commented
Awesome. Thank you!