Skip to content

Commit f6ab30b

Browse files
authored
Switch to nginx ingress module (#195)
* breaking: Switch to nginx ingress module which now uses helm / NLB * Fixed module name
1 parent 5cb8495 commit f6ab30b

9 files changed

Lines changed: 23 additions & 374 deletions

File tree

templates/kubernetes/terraform/environments/prod/main.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,4 +102,8 @@ module "kubernetes" {
102102
notification_service_highly_available = true
103103

104104
cache_store = "<% index .Params `cacheStore` %>"
105+
106+
# Should not be less than 2 for production. 2 can handle a significant amount of traffic and should give a reasonable amount of redundancy in the case of
107+
# needing to do deployments of the controller or unexpected termination of a node with a controller pod on it.
108+
nginx_ingress_replicas = 2
105109
}

templates/kubernetes/terraform/environments/stage/main.tf

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,4 +101,6 @@ module "kubernetes" {
101101
notification_service_highly_available = false
102102

103103
cache_store = "<% index .Params `cacheStore` %>"
104+
105+
nginx_ingress_replicas = 1
104106
}

templates/kubernetes/terraform/modules/kubernetes/cert_manager.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ data "aws_iam_policy_document" "cert_manager_policy_doc" {
177177
"route53:ListResourceRecordSets"
178178
]
179179

180-
resources = [for index, domain in var.external_dns_zones : "arn:aws:route53:::hostedzone/${data.aws_route53_zone.zones[index].zone_id}"]
180+
resources = [for zone in data.aws_route53_zone.zones : "arn:aws:route53:::hostedzone/${zone.zone_id}"]
181181
}
182182

183183
statement {

templates/kubernetes/terraform/modules/kubernetes/external_dns.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ data "aws_iam_policy_document" "external_dns_policy_doc" {
3434

3535
actions = ["route53:ChangeResourceRecordSets"]
3636

37-
// data.aws_route53_zone.zones declared in ./cert-manager.tf
38-
resources = [for index, domain in var.external_dns_zones : "arn:aws:route53:::hostedzone/${data.aws_route53_zone.zones[index].zone_id}"]
37+
# data.aws_route53_zone.zones declared in ./cert-manager.tf
38+
resources = [for zone in data.aws_route53_zone.zones : "arn:aws:route53:::hostedzone/${zone.zone_id}"]
3939
}
4040
}
4141

templates/kubernetes/terraform/modules/kubernetes/ingress/README.md

Lines changed: 0 additions & 4 deletions
This file was deleted.

templates/kubernetes/terraform/modules/kubernetes/ingress/main.tf

Lines changed: 0 additions & 350 deletions
This file was deleted.

0 commit comments

Comments
 (0)