Skip to content

Commit

Permalink
Merge pull request #184 from tablexi/dh-optionally-turn-off-txi-offic…
Browse files Browse the repository at this point in the history
…e-access

Optionally expose RDS to Table XI office
  • Loading branch information
hammerdr authored Jan 5, 2021
2 parents 9ebac65 + 954e3a7 commit 4e63bc5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion aws/rds/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ resource "aws_security_group" "sg_on_rds_instance" {
vpc_id = var.vpc_id

ingress {
cidr_blocks = concat([local.table_xi_office_cidr_block], var.sg_cidr_blocks)
cidr_blocks = var.expose_to_txi_office ? concat([local.table_xi_office_cidr_block], var.sg_cidr_blocks) : var.sg_cidr_blocks
from_port = local.port
protocol = "tcp"
security_groups = var.security_groups_for_ingress
Expand Down
6 changes: 6 additions & 0 deletions aws/rds/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -141,3 +141,9 @@ variable "vpc_security_group_ids" {
default = []
}


variable "expose_to_txi_office" {
description = "include TXI Office IP in security group"
type = bool
default = true
}

0 comments on commit 4e63bc5

Please sign in to comment.