Service names updating across environments
afterlife7481
PROOP

2 months ago

I made a copy of my environment (staging copied to production)

both environment have their own postgres database, yet when I rename the postgres service on staging is automatically updates the name on production.

This seems unusual behaviour no ?

The agent says that: service names are global across your entire project.

not sure this is correct if the services are distinct.

Ideally I want my my staging postgres service to be calles postgres-staging and my production one to be called postgres-production.

Any help welcomed.

Thanks

Solved

2 Replies

Railway
BOT

2 months ago

That's correct, service names are project-wide, not per-environment. Renaming a service in one environment renames it everywhere. To give each database a distinct name, you would need separate services rather than the same service across environments. That said, when you clone an environment, each environment already gets its own independent Postgres instance (with its own volume and credentials), so the underlying databases are fully isolated even though they share a service name.


Status changed to Awaiting User Response Railway about 2 months ago


Railway

That's correct, service names are project-wide, not per-environment. Renaming a service in one environment renames it everywhere. To give each database a distinct name, you would need separate services rather than the same service across environments. That said, when you clone an environment, each environment already gets its own independent Postgres instance (with its own volume and credentials), so the underlying databases are fully isolated even though they share a service name.

afterlife7481
PROOP

2 months ago

thanks for clarifying that!


Status changed to Awaiting Railway Response Railway about 2 months ago


Status changed to Solved Railway about 2 months ago


Welcome!

Sign in to your Railway account to join the conversation.

Loading...