2 CNAMEs from domain to Railway, ANAME to subdomain
shxkm
PROOP

a year ago

I've the following setup:

sub.mydomain.com -> railway
mydomain.com -> railway

Both work properly and railway reports they're fine.

But I've also configured an ALIAS record from myOtherDomain.com -> sub.mydomain.com. Unfortunately, that doesn't seem to work. With dig myOtherDomain.com, I can see an IP from Google, which I assume is GCP. Am I missing something?

Solved

32 Replies

shxkm
PROOP

a year ago

2 CNAMEs from domain to Railway, ALIAS to subdomain


shxkm
PROOP

a year ago

1b0d51d3-f173-4fd6-bf29-f0025eae2d1a


shxkm
PROOP

a year ago

Actually, from a fresh machine it does seem to be redirecting but is giving a privacy warning. Is this a limitation from Railway’s side?


shxkm
PROOP

a year ago

The error is gone, but now I get Railway’s Not Found page.

Must Railway know of all domains that point to my domains? If I have an ALIAS from OtherDomain.com to sub.mydomain.com (registered with railway), do I also need to provision OtherDomain.com at Railway?


a year ago

you need to use a CNAME, and yes the domain does have to be added to the applicable service


shxkm
PROOP

a year ago

Does Railway support A records at all? I may have a use case where customer provided domains may need to point to my own server.


a year ago

we only support CNAMEs, sorry


shxkm
PROOP

a year ago

Any workarounds you can think of for this case?


a year ago

you add their domain to your service and give them the CNAME to set


shxkm
PROOP

a year ago

That’s not gonna be very scalable. Anything else I can do here? (BTW: last time we corresponded you weren’t at Railway, congrats on the new role)


a year ago

You can use Cloudflare's to manage your domains, and then you can use a snippet to overwrite the host header so that you only need one domain on Railway, requires Cloudflare Pro though


shxkm
PROOP

a year ago

Thanks. Got any pointers?


a year ago

honestly I forgot what the offering from them is called to make it happen


shxkm
PROOP

a year ago

What about using nginx as a reverse proxy?


a year ago

that won't work, you'd need to have the domain in railway still since we do host based routing


shxkm
PROOP

a year ago

Even if this proxy is hosted outside of railway?


a year ago

oh then yes it could work


a year ago

but if you're going that route, use caddy


shxkm
PROOP

a year ago

I mean customers would point to the proxy, proxy to railway


a year ago

yeah you can do that, or you can do it with Cloudflare, I'd definitely go the Cloudflare route


shxkm
PROOP

a year ago

With workers? Because host rewriting is available in the ENTERPRISE plan


a year ago

you can do host rewriting with snippets on pro


a year ago

not using workers


shxkm
PROOP

a year ago

Got it. $25/mo is a bit much for this MVP. If I go the caddy route, I can only host it outside of Railway?


a year ago

wouldn't you bake that price into the price you pass onto your customers?


shxkm
PROOP

a year ago

For sure. But I’d like to do this with CF only after a customer actually wants (pays) for it.


a year ago

fair enough


a year ago

caddy it is


shxkm
PROOP

a year ago

Must it be outside of Railway though?


a year ago

yes, somewhere that doesn't do host based routing


shxkm
PROOP

a year ago

🙏


a year ago

!s


Status changed to Solved brody about 1 year ago


Loading...