Question about the URL when publishing a new template on Railway
otegami
FREEOP

a month ago

I’m planning to publish a new template on Railway, but I’m not sure how the public URL for the template is determined.
Could you please let me know what defines the final URL when a template is published?

I’ve checked the documentation, but I couldn’t find a section that explains this detail, so I wanted to ask here directly.

Thank you so much for your time and help!

Solved

0 Replies

dev
MODERATOR

a month ago

What do you mean by how the public URL is determined? Like the name of the railway provided domain or like the value of RAILWAY_PUBLIC_URL ?


otegami
FREEOP

a month ago

the name of the railway provided domain

Ah, got it! I meant the name in the Railway-provided domain.
For example, when publishing a template, it gets a URL like
https://railway.com/deploy/xxxx,
and I was wondering how the xxxx part is decided.


dev
MODERATOR

a month ago

ooh


dev
MODERATOR

a month ago

it gives a subdomain like xxx.up.railway.app


dev
MODERATOR

a month ago

xxx is just the name of the service but if the domain is taken it'll add a randomized string after


otegami
FREEOP

a month ago

Thanks for clarifying!
Just to make sure I got it right — if the name is already taken, Railway adds a random string, correct?
And the xxx part (service name) isn’t something we can control ourselves, right?


dev
MODERATOR

a month ago

although you do have to enable the public domain in the template service settings for it to happen


dev
MODERATOR

a month ago

you can set the service name


dev
MODERATOR

a month ago

if you're on your service settings just click on the service name to edit it


adam
MODERATOR

a month ago

are you referring to template publish urls here? Or service publicly accessible urls? (eg, website frontend)


adam
MODERATOR

a month ago

Fragly’s advice is applicable to services


otegami
FREEOP

a month ago

Thanks for the follow-up!
Yes, I was referring to the template publish URLs — not the service URLs.


adam
MODERATOR

a month ago

You do not have the option to manipulate template publish urls, as far as I know


otegami
FREEOP

a month ago

Thank you so much!
So, I understand that the URL generated when publishing a template can’t be controlled by us.
I really appreciate your support!


dev
MODERATOR

a month ago

what i said is applicable to both templates and services, it follows this format:
{template service name}-{environment}-{uuid}.[up.railway.app](up.railway.app)

  • template service name is within your control

  • environment depends on where the user deploys it, usually production

  • uuid is a random 4 letter string if {template service name}-{environment} is taken


dev
MODERATOR

a month ago

!s


Status changed to Solved dev about 1 month ago


Loading...