Cannot get Obsidian publish to work with a custom domain

After waiting the entire day for this to start resolving now it resolves but there is a redirect error

The page isn’t redirecting properly

An error occurred during a connection to domain.com.

This problem can sometimes be caused by disabling or refusing to accept cookies.
The page isn’t redirecting properly

An error occurred during a connection to www.domain.com.

This problem can sometimes be caused by disabling or refusing to accept cookies.

It doesn’t work with the page rule active or disabled

Others had the exact same problem two years ago and it’s still a problem. Where is the documentation and the solution? Setting up a custom domain for Obsidian Publish is a nightmare. Isn’t this supposed to be easy?