I've added custom domains (Route53) to my api's an...
# sst
s
I've added custom domains (Route53) to my api's and static site across diff stages - I've deployed changes across my stacks but its' been stuck on checking deploy status... for over 5 hours now. Is this normal? I guess it takes a while provisioning ssl certificate.
a
Have you created the zonefiles using the CDK constructs as part of this?
Or created them manually?
s
Hi Alistair, I created new hosted zones manually in Route 53 - such as dev.domain.co > staging.domain.co Then in construct mapped to
Copy code
const zone = MAPPING[scope.stage] || '<http://dev.outflo.co|dev.outflo.co>';
    const domain = MAPPING[scope.stage] || `${scope.stage}.<http://dev.outflo.co|dev.outflo.co>`;
a
Ah okay so you are following @thdxr example? Have you configured the name servers on your domain to be those in your
<http://domain.co|domain.co>
zone? Check the CLoudFormation console and see which resources it is waiting on or has failed on.
s
Yeah following his example from video - 1. do you mean adding a NS record to domain.co hosted zone? If so no I haven't just created a hosted zone for each. 2. Thanks I'll check cloudformation console for answers
t
Is your domain configured to actually use route53?
Wherever you registered it, is its name servers pointing to route53?
s
I switched from GoDaddy to Route53 some time ago, but I will double check on config side stuff is correct.
Thanks both I have a few places to start looking at what might be going on
t
Basically when AWS create a certificate it adds some DNS records, waits for it to propagate, then confirms everything. Usually takes a few minutes
Do you see that DNS record in route53
Hm that's really weird. Can you go to the certificates section in the console and see if you can find the one it's trying to create
s
Any chance I'm trying to do too much at one time concurrently?
t
Too much at once shouldn't be a problem for AWS haha
Does clicking into the certificate show anything about what it's waiting for? Also curious if the DNS records did get created
Yeah check if that cname is actually there
Can you paste the cname here I'll check some stuff
I'm wondering if your root domain is delegating to your dev subdomain properly. Maybe route53 is creating records in your dev zone but that's not actually being used
s
So the cname does exist in both certificates and route53 under hosted zone dev.outflo.co
_<http://9d4a5cb377cd027bae68c9719d250978.api.sam-dev.dev.outflo.co|9d4a5cb377cd027bae68c9719d250978.api.sam-dev.dev.outflo.co>
t
Ah I just noticed
In your root domain you need to add NS records for dev.outflo.co pointing to the NS in the dev zone
s
Dam it, sorry @thdxr
t
np! Hope this is the issue
s
Will do that and hopefully works okay
It's taken a while but I resolved the issue in the end. I'll share in case anyone else gets same problem. Initially my DNS was managed by GoDaddy, a few months ago I was a fool and didn't read migration docs properly: https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/migrate-dns-domain-in-use.html I missed critical step 7 and did not add my NS values to my name servers in registered domain (which I transferred from GoDaddy) - they were still pointing to GoDaddy NS value thus AWS was unable to verify my domain ownership