From 50ee85553f7473c9d4e680b7cbb172de5304798d Mon Sep 17 00:00:00 2001 From: Magnus Henoch Date: Mon, 11 Dec 2023 13:15:45 +0000 Subject: [PATCH] fix: FQDN detection when using an existing ALB (#379) --- examples/github-separate/main.tf | 1 + main.tf | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/github-separate/main.tf b/examples/github-separate/main.tf index 9ab9bfd5..2c63409e 100644 --- a/examples/github-separate/main.tf +++ b/examples/github-separate/main.tf @@ -67,6 +67,7 @@ module "atlantis" { valueFrom = try(module.secrets_manager["github-webhook-secret"].secret_arn, "") }, ] + fqdn = module.alb.dns_name } service = { diff --git a/main.tf b/main.tf index 1fc1d1bc..1ed4ba34 100644 --- a/main.tf +++ b/main.tf @@ -1,8 +1,7 @@ locals { # Atlantis atlantis_url = "https://${try(coalesce( - try(var.atlantis.fqdn, null), - module.alb.route53_records["A"].fqdn, + try(var.atlantis.fqdn, module.alb.route53_records["A"].fqdn, null), module.alb.dns_name, ), "")}"