I am not getting what everything is telling me I should be getting. Can someone shed some light on what I am doing wrong so I can have subdomains using my custom url sendmetraveling.com that is assigned to my branches staging-initial and staging-final?
Hi Rob, welcome to the Netlify community,
Are you using Netlify’s DNS hosting for the
this article might help you figure out how to set that up.
I am using Netlifys domain servers
Interesting, I see the DNS servers as Netlify
But your site is resolving to Digital Ocean
But I doubt that has anything to do with the issue.
Yeah, thats what the docs say to do.
That is an IP address we currently use. The Digitial Ocean IP address is for one of our CDN nodes so this does look like the Managed DNS is working correctly.
For this to work, first there must be a normal branch deploy for these branch (not a pull request “deploy preview” deploy). Right now, I’m not seeing the “normal” branch deploys for this site here.
There is more documentation about how to make the “normal” branch deploys and add the subdomain here: Branch subdomains.
If these instructions don’t work as promised and/or there are any other questions, we are always happy to follow-up and/or answer.
So the normal branch that is deployed is the master branch.
In one of the screenshots above, it shows that I have the continuous deployment set up to deploy a site for the master branch and staging final and staging initial.
The .toml file I have also uses the context.branch phrasing that is in the docs as well.
The issue is that “New SubDomain” button is not appearing on the page for me (as shown in the above screenshot’s)
This is what my .toml file looks like in every branch. There are 4 branches other than the master branch.
[build] base = "/sendmetraveling/" publish = "/sendmetraveling/build/" command = "yarn build" [context.branch-deploy] command = "make staging"
You need to successfully deploy a branch deploy in order to have a URL for it. The master branch is your production branch so it’s not a separate branch deploy. You have several other branches like this one but these builds have failed so they don’t get branch subdomains.
The error I see in that branch build is:
You need to resolve the build issues with your branches so that you can have branch subdomains.
Ok, that’s a good direction to go in, but I am still at a loss of what I need to do or how to do it.
netlify.toml file has
make staging as the command for a branch deploy, but you have no
Makefile in your repo so
make doesn’t know what to do with the
make staging command you’ve given it, hence the “No rule to make target ‘staging’” error I think.
At a guess you’ve copied that from somewhere…? You can either replace
make staging with
yarn build as per your “default” command or, I think, remove the whole
context.branch-deploy section entirely.
Alex, this did it! Thanks all for your help and support!
@alexrussell Great catch. Sometimes it is right in front of us.