a month ago
Hi,
I'm trying to add a new custom domain to my service.
p.domain.com
When Railway is showing the records that I need to configure in my DNS I'm expecting:
- A p CNAME record with a value
- A railway-verify.p TXT record with a value
What I'm getting is:
- A @ CNAME record with a value
- A railway-verify TXT record
Why is it asking for a root @ records if I provided a specific subdomain?
11 Replies
Status changed to Open Railway • about 1 month ago
a month ago
Railway is parsing p.domain,com and treating "p" as the subdomain of domain.com, but displaying the dns records relative to the root zone (qweqweqweqwe.p, meaning railway detected the registrable domain as qweqweqwe.o which is nonsensical).
The real issue is that railway strips the subdomain from the custom domain you enter and shows dns records relative to the apex domain. so when you enter p.domain.com, railway shows:
CNAME name: @ → meaning "point the root of p.domain.com... " — but that's not how DNS works. p.domain.com is itself a subdomain, so the record name in your DNS provider should be p, not @.
how to fix this:
Railway's UI is correct in value, but the Name column is misleading. Here's what to actually enter in your DNS provider:
CNAME: p, value: 08huskbx.up.railway.app
TXT: _railway-verify.p, value: railway-verify=322563af...
The @ shown by Railway means "the root of the domain Railway detected", which in your case is p relative to domain.com. So enter p as the CNAME name, and _railway-verify.p as the TXT name, in your DNS provider (Cloudflare/Route53/etc.).
Why does Railway show @? It parses the public suffix list to find the registrable domain, then expresses all record names relative to that apex. Since you're adding a subdomain of your apex, the relative name becomes @ from Railway's perspective, but your DNS provider expects the actual label (p).
let me know if that fixed the issue.
zx1234r
Railway is parsing p.domain,com and treating "p" as the subdomain of domain.com, but displaying the dns records relative to the root zone (qweqweqweqwe.p, meaning railway detected the registrable domain as qweqweqwe.o which is nonsensical). The real issue is that railway strips the subdomain from the custom domain you enter and shows dns records relative to the apex domain. so when you enter p.domain.com, railway shows: CNAME name: @ → meaning "point the root of p.domain.com... " — but that's not how DNS works. p.domain.com is itself a subdomain, so the record name in your DNS provider should be p, not @. how to fix this: Railway's UI is correct in value, but the Name column is misleading. Here's what to actually enter in your DNS provider: CNAME: p, value: 08huskbx.up.railway.app TXT: _railway-verify.p, value: railway-verify=322563af... The @ shown by Railway means "the root of the domain Railway detected", which in your case is p relative to domain.com. So enter p as the CNAME name, and _railway-verify.p as the TXT name, in your DNS provider (Cloudflare/Route53/etc.). Why does Railway show @? It parses the public suffix list to find the registrable domain, then expresses all record names relative to that apex. Since you're adding a subdomain of your apex, the relative name becomes @ from Railway's perspective, but your DNS provider expects the actual label (p). let me know if that fixed the issue.
a month ago
So you are saying it's just a visual bug right? I'll test with a subdomain to see what happens
avecino
So you are saying it's just a visual bug right? I'll test with a subdomain to see what happens
a month ago
I was using a custom domain that was not verified before, using a previously verified domain works as expected.
Status changed to Solved avecino • about 1 month ago
avecino
I was using a custom domain that was not verified before, using a previously verified domain works as expected.
a month ago
good to know!
a month ago
In your screenshot you show the domain qweqweqweqwe.p leads to it asking you to add an @ record, but the domain there doesn't have a subdomain, that's just a domain with qweqweqweqwe as the domain and p as the TLD, that seems correct to me. Unless I'm misunderstanding something, mind clarifying? What happens when you add p.domain.com?
Status changed to Awaiting User Response Railway • about 1 month ago
dev
In your screenshot you show the domain `qweqweqweqwe.p` leads to it asking you to add an `@` record, but the domain there doesn't have a subdomain, that's just a domain with `qweqweqweqwe` as the domain and `p` as the TLD, that seems correct to me. Unless I'm misunderstanding something, mind clarifying? What happens when you add `p.domain.com`?
a month ago
I blurred the domain in the image, that's why you can't see it.
In this project I haven't used xdomain.com when I add a new custom domain new.xdomain.com I get this:
I'm guessing this happens because it's the first time using this domain in this project maybe?
I would expect to only need the record new, not @.. Not sure if this is intended or not.
Attachments
Status changed to Awaiting Conductor Response Railway • about 1 month ago
a month ago
ah okay, thank you very much for clarifying, that is very odd
even weirder, I'm not able to reproduce this at all, both on domains never verified before and on domains that have been verified... very strange
is this a blocker for you or did you manage to get it working?
Status changed to Awaiting User Response Railway • about 1 month ago
dev
ah okay, thank you very much for clarifying, that is very odd even weirder, I'm not able to reproduce this at all, both on domains never verified before and on domains that have been verified... very strange is this a blocker for you or did you manage to get it working?
a month ago
I managed to get it working since the problematic domain is not the one I need for that project, and with the other domain it's working correctly.
Status changed to Awaiting Conductor Response Railway • about 1 month ago
Status changed to Open brody • about 1 month ago
a month ago
I experienced the same thing just now – I'm trying to add a custom domain for client.mydomain.com and the cname given to me is @. However, if I use clients.mydomain.com I get the clients cname as I'd expect. I also tried using client.mydomain.com and setting the name values to what I think they should have been (client and _railway-verify.client) but that didn't seem to work for me.
Attachments
18 days ago
Hi railway team,
It seems like my issue is related to that specific domain, it doesn't happen with other domains it's only prismatechcorp.com.
Here is a video replicating the problem:
dev
ah okay, thank you very much for clarifying, that is very odd even weirder, I'm not able to reproduce this at all, both on domains never verified before and on domains that have been verified... very strange is this a blocker for you or did you manage to get it working?
18 days ago
Hi railway team,
It seems like my issue is related to that specific domain, it doesn't happen with other domains it's only prismatechcorp.com.
Here is a video replicating the problem:
