our first question would be about where the content for the subdomain is coming from.
there needs to be a branch that has the exact name and spelling of the subdomain you are trying to deploy it to. our system matches the two up for you.
before we dig in further, can you confirm this is the case?
The CNAME points to another Netlify site repo we own and is not a branch from the main site repo. I was under the impression that you can add a CNAME and point it to a Netlify site. This is not a DNS entry automatically added when making a branch.
The goal was to have the sub domain served from another repo that can be separately managed and not part of the main repo. It seems using a branch would be better when working on reviewing updates to a repo.
How would you suggest serving up a subdomain from another Netlify repo?
thanks for that info, @mnaz . I have broad knowledge generally speaking, but am not a DNS expert so I’m going to ask a colleague to weigh in who can assist. We’ll get you up and running, in the mean time, if anything changes do let us know.
So I need to add wear.solshades.io to the kind-panini-a730bb site, is the image correct? I do not want to cause any issues with the site solshade.io that is already in place.
So far looks good and I removed the CNAME I added because a NETLIFY was automatically added for it.
I waited and it propagated right away and worked!!
Thanks for the help, I was a little nervous making some of these changes and your help was awesome.
This might be something to add to your docs, it seems like a reasonable setup but has a number of steps
Hi @perry - I’m trying to do something similar but I want to just make sure I have it correct and not wipe out all the DNS settings on the primary account.
Netlify Account 1:
I have the DNS settings set up here - example.com. We have ~20 DNS records so it would be really bad to lose it or mess it up.
Netlify Account 2: (where my Netlify site is hosted)
I want to set up test.example.com to point to this Netlify site.
When I am in account 2 and go add the new custom domain for test.example.com – I get the warning above shown in mnaz’s screenshot. I just want to confirm - since our domain is already set up on Netlify in Account 1 - aside from adding a new Netlify record - it will not mess up any of the other settings, ie. it will not move any of the domain registration to account 2. Is that correct?
While the DNS configuration won’t move, you still won’t be able to connect the domain. We do not allow an apex domain or a DNS zone to exist in one account and a subdomain to be added in another account. Both need to exist in the same account.
Hi @hrishikesh - ok we are scratching our heads and can’t find any way around this. I was wondering if you could help us out.
So we tried using the redirect file on the main site (that’s in account 1) and do a 200 redirect to site 2 (on account 2) - it works when we redirect within the same site but not when we point it to the site on account 2.
Ideally - we can just set up a subdomain on the domain from account 1 to point to the Netlify site on account 2. We are the same company, but working in different division so we had different Netlify sites set up. Is there anyway you can help us on the backend with allowing this to work, or connecting our accounts somehow?
We can allow sharing the domains across teams, but this is a security risk and most likely would not want to leave the setting open. If you wish to absolutely enable it, you can let us know (here or in the helpdesk) and we can do it for you.
Hi @hrishikesh - we were able to get a work around. I am testing it out now to see if it works out.
If you were to enable it - would the setting be open just for our 2 accounts, or for anyone?
@audrey - ah ok got it. I ended up breaking off my app and having a mini app in the 1st account. It seems to be working out for now but good to know for the future around the domain sharing feature flag. Thank you for your response!