Skip to content

Commit

Permalink
move domain and hosted zone to vars
Browse files Browse the repository at this point in the history
  • Loading branch information
Luke Lombardi committed Jan 18, 2024
1 parent 4902c16 commit 41bda93
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
5 changes: 2 additions & 3 deletions deploy/aws/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ output "aws_load_balancer_controller_role_arn" {

# SSL Certificate for the service exposed
resource "aws_acm_certificate" "ssl_cert" {
domain_name = "eng-stage.slai.io"
domain_name = var.domain
validation_method = "DNS"

lifecycle {
Expand All @@ -335,8 +335,7 @@ resource "aws_route53_record" "cert_validation" {
}
}

# TODO: don't hardcode this
zone_id = "Z07081541B2HAA9KWC78W" # aws_route53_zone.eng_stage.zone_id
zone_id = var.domain_hosted_zone_id
name = each.value.name
type = each.value.type
ttl = 60
Expand Down
8 changes: 8 additions & 0 deletions deploy/aws/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,11 @@ variable "cluster_name" {
variable "cluster_version" {
default = "1.28"
}

variable "domain" {
default = "eng-stage.slai.io"
}

variable "domain_hosted_zone_id" {
default = "Z07081541B2HAA9KWC78W"
}

0 comments on commit 41bda93

Please sign in to comment.