Difficulty with custom domain

Thank you for getting my static website’s Pages deployment working.

Now I’m trying to add a custom domain to my Pages deploy and when I save I see the following message:

Domains saved but failed to sync with StaticHost: StaticHost site not found. The site may not exist.

And I’m not having any luck accessing the site through the custom domain.

Same issue as for your previous post. We first need to look into it in more detail as adding custom domains through our integration is broken at the moment. This is the same process code-wise as adding the initial codefloe.page domain.

We added your new primary domain manually just now.

Thank you, it is currently functioning.

(On a separate issue my domain registrar, Hover, doesn’t support top-level CNAME redirects, so I had to resort to setting an A record to the IP address that my static page resolves to, which of course is subject to change…)

One more domain please if you would be so kind: the www variant, and that should take care of it.
(I think I might have a way around Hover not allowing apex-level CNAME records.)

:white_check_mark: just added the www variant

If I may ask: Did you find a solution for your CNAME issue?

I followed the statichost.eu docs ( Custom domains - statichost.eu , step 2) used an ALIAS and it’s working fine!

@codefloe , maybe this solution can be added to the docs?

My idea didn’t work. So I’m still just setting the A record and hoping statichost’s IP address doesn’t change.

There’s nothing special here, i.e. a CNAME entry to the main domain configured in SH resp. within the Pages setting in CF will work. We have multiple sites configured this way.

A records aren’t a robust solution here due to the possibly changing IPs. Though they are the only way to configure APEX domains. Subdomains (like www) should always use CNAME records. See also the statichost docs.

WRT to docs: ideally we don’t duplicate other existing docs. Maybe we can link to the statichost docs at an appropriate place within the CF docs? PR welcome :slight_smile: