From 3cecab58a8665a4517c8259d4b35631e4af22eb6 Mon Sep 17 00:00:00 2001 From: Kevin Mahoney Date: Tue, 17 Oct 2023 15:00:12 +0200 Subject: [PATCH 1/2] add variable for additional security group IDs --- main.tf | 7 ++++--- variables.tf | 6 ++++++ 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/main.tf b/main.tf index ba1d8aa..a7922f9 100644 --- a/main.tf +++ b/main.tf @@ -14,9 +14,10 @@ module "tailscale_subnet_router" { context = module.this.context tags = module.this.tags - vpc_id = var.vpc_id - subnet_ids = var.subnet_ids - key_pair_name = var.key_pair_name + vpc_id = var.vpc_id + subnet_ids = var.subnet_ids + key_pair_name = var.key_pair_name + additional_security_group_ids = var.additional_security_group_ids create_run_shell_document = var.create_run_shell_document session_logging_kms_key_alias = var.session_logging_kms_key_alias diff --git a/variables.tf b/variables.tf index f659c65..a505d4e 100644 --- a/variables.tf +++ b/variables.tf @@ -12,6 +12,12 @@ variable "subnet_ids" { description = "The Subnet IDs which the Tailscale Subnet Router EC2 instance will run in. These *should* be private subnets." } +variable "additional_security_group_ids" { + default = [] + type = list(string) + description = "Additional Security Group IDs to associate with the Tailscale Subnet Router EC2 instance." +} + variable "create_run_shell_document" { default = true type = bool From 64f2aef41bb382086301b6131de3e8d7b145a417 Mon Sep 17 00:00:00 2001 From: Kevin Mahoney Date: Tue, 17 Oct 2023 15:03:47 +0200 Subject: [PATCH 2/2] Update main.tf --- main.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.tf b/main.tf index a7922f9..82f4828 100644 --- a/main.tf +++ b/main.tf @@ -18,7 +18,7 @@ module "tailscale_subnet_router" { subnet_ids = var.subnet_ids key_pair_name = var.key_pair_name additional_security_group_ids = var.additional_security_group_ids - create_run_shell_document = var.create_run_shell_document + create_run_shell_document = var.create_run_shell_document session_logging_kms_key_alias = var.session_logging_kms_key_alias session_logging_enabled = var.session_logging_enabled