Skip to content

Commit 2068088

Browse files
committed
feat: allow pre-creation of EIPs for adding to ip authorized list
1 parent 8abfeeb commit 2068088

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ data "aws_ami" "main" {
114114
}
115115

116116
resource "aws_eip" "main" {
117-
count = var.stack_pelotech_nat_enabled ? length(module.vpc.azs) : 0
117+
count = (var.stack_pelotech_nat_enabled || var.stack_create_pelotech_nat_eip) ? length(module.vpc.azs) : 0
118118
tags = {
119119
Name = "nat-${var.stack_name}-${count.index}"
120120
}

variables.tf

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ variable "stack_create" {
88
default = true
99
description = "should resources be created"
1010
}
11+
variable "stack_create_pelotech_nat_eip" {
12+
type = bool
13+
default = false
14+
description = "should create pelotech nat eip even if NAT isn't enabled - nice for getting ips created for allow lists"
15+
}
1116
variable "eks_cluster_version" {
1217
type = string
1318
default = "1.35"

0 commit comments

Comments
 (0)