Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question about: https://exanubes.com/blog/sharing-a-domain-name-across-multiple-aws-accounts #1

Closed
ImreC opened this issue Feb 4, 2023 · 4 comments
Assignees

Comments

@ImreC
Copy link

ImreC commented Feb 4, 2023

Hi, I read your blog post about sharing a domain name across multiple AWS accounts. Did requesting a certificate through ACM using DNS validation work for you using this approach or are there any additional steps? It seems to get stuck on Pending Validation and you specifically mention getting certificates in the article. Apologies for reaching out this way. I hope you don't mind.

@exanubes
Copy link
Owner

exanubes commented Feb 8, 2023 via email

@ImreC
Copy link
Author

ImreC commented Feb 9, 2023

Really appreciate the response. I am now leaning towards catching the validation email with an MX record in the main account and an SNS + lambda handler to get the link, but this is obviously like something more automated. The docs on AWS are really unclear about this.

For example this blog post doesn't really give any information on how to do it at all:
https://aws.amazon.com/premiumsupport/knowledge-center/acm-export-certificate/

This is on the cloudformation page on creating the certificate through there:
image

I also wasn't able to create it through the console though. Same problem. It just gets stuck at validating regardless of DNS records being available. I tried the main account as well as the sub-domain account.

@exanubes
Copy link
Owner

@ImreC So here's the thing. Not sure what kind of setup you're running so I'm gonna tell you about mine.

I have my domain (exanubes.com) in route53, but the hosting and ssl is actually handled via netlify. To do that I had to swap the ns record for apex in route53 to netlify's ns servers.
To summarize I have the same ns records for exanubes.com in netlify dns settings and in route53.

Now let's say I want to have a subdomain in a different hosted zone e.g test.imrec.exanubes.com. Normally I would just put the subdomain's name servers in a ns record for the apex, however, I'm hosting via netlify so I had to go to netlify's console and add them there.

To be frank I did not check if I need them in route53 and netlify. I added the ns record for the subdomain in both places.

NS Record inside the test.imrec.exanubes.com hosted zone

Screenshot 2023-02-10 at 16 51 05

NS Record for the test.imrec.... hosted zone inside apex HZ

Screenshot 2023-02-10 at 16 51 27

NS Records for the test.imrec.... inside Netlify DNS Settings

Screenshot 2023-02-10 at 16 51 40

Issued ACM Certificate

image

Hope this helps, good luck!

@ImreC
Copy link
Author

ImreC commented Feb 13, 2023

@exanubes I felt like I was trying this before, but I might have made a copy mistake in the NS record or something. This works perfectly now. Thanks a lot! Really appreciate your help :) Let me know if I can return the favor.

@ImreC ImreC closed this as completed Feb 13, 2023
@exanubes exanubes pinned this issue Feb 19, 2023
@exanubes exanubes self-assigned this Feb 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants