Hi! I am hosting a landing page on Railway with a custom domain using a CNAME record.
Now, I am also setting up an email client via Namecheap (their PrivateEmail service). To send emails from @mydomain.com, I have to add an MX record and a TXT record (SPF).
However, the DNS spec states that, "if a CNAME record is present, no other data should be present" (https://serverfault.com/questions/834320/adding-both-cname-and-txt-dns-records-for-one-subdomain).
Because of this, my emails fail the SPF check while the CNAME is active.
I have tried removing the CNAME record, which makes the SPF succeed...
This seems like a very common usecase - am I missing something?
Do I somehow not have to set up MX/TXT records on the root domain (host: @) to succeed SPF check while sending emails from [email protected]?
Thanks!