Worker Custom Domain + Custom Hostname = 522 Error

I created a Worker that has a custom domain assigned to it (origin-domain.com for this example).

I then turned on custom hostnames for origin-domain.com so that I could have multiple domains CNAME’d to that single domain.

However, when I tried to CNAME vanity-domain.com to origin-domain.com, Cloudflare returned a 522 error.

Any idea why?

The request chain (as I understand it):
vanity-domain.com => CNAME (origin-domain.com) => origin-domain.com => custom worker domain => worker

I believe you need to have the domain added to your worker in order for it to be served. So here you would need to add vanity-domain.com to your worker.

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.