Skip to content

Commit

Permalink
Merge pull request #97 from appuio/feat/lb-additional-sgs
Browse files Browse the repository at this point in the history
Introduce new optional variable to attach additional security groups to the LBs
  • Loading branch information
simu authored Jan 6, 2025
2 parents 574c399 + 1907c59 commit 77c9402
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
7 changes: 4 additions & 3 deletions lb.tf
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@ module "lb" {
enable_proxy_protocol = var.lb_enable_proxy_protocol
additional_networks = var.additional_lb_networks

cluster_security_group_ids = [
exoscale_security_group.all_machines.id
]
cluster_security_group_ids = concat(
[exoscale_security_group.all_machines.id],
var.additional_lb_security_group_ids
)

additional_affinity_group_ids = var.additional_affinity_group_ids

Expand Down
6 changes: 6 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -232,3 +232,9 @@ variable "additional_lb_networks" {
description = "List of UUIDs of additional Exoscale private networks to attach"
default = []
}

variable "additional_lb_security_group_ids" {
type = list(string)
default = []
description = "List of additional security group IDs to configure on the LBs"
}

0 comments on commit 77c9402

Please sign in to comment.