I am having a problem deploying an app using a custom domain. I am using Terraform to deploy the app and all of the pieces deploy correctly apart from the setting of the Public URL for the front end reverse proxy.
The container deploys correctly and passes health checks but the external mapping to the Public URL shows on the service detail screen as my-custom-domain.comundefined and of course the service is not then externally available. I don’t know where that undefined string is coming from.
The domain is shown as active (I have a wildcard entry on the DNS so I am not updating the DNS records with Terraform) and attached to the correct Koyeb app.
However if I got to the service / Settings / Exposed Ports and untick and then re-tick the Public option then the Public URL fixes itself.
Is this just a timing issue? I have waited for 10 minutes and nothing changed until I flipped that public slider on an off.
The relevant sections of the terraform:
resource "koyeb_domain" "my-domain" {
name = "app-${var.stage}.my-custom-domain.com"
app_name = koyeb_app.bna-app.name
depends_on = [
koyeb_app.bna-app
]
}
resource "koyeb_service" "reverseproxy-service" {
app_name = koyeb_app.bna-app.name
definition {
name = "reverse-proxy"
ports {
port = 80
protocol = "http"
}
....
Any suggestions appreciated.