MICROSIVE

Railway hosting for apps with workers and a database

Some apps are more than a website: a web server, a queue worker, a database and Redis that all need to reach each other. Railway runs those pieces together in one project.

Reviewed by: Rahul Jaiswar, founder

Where we use it

Microsive ATS is hosted on Railway.

What we check

A deploy sends what is on the machine rather than what is committed, so we commit first and check the running version afterwards.

We also deploy and host client apps on Railway, and the account stays in the client’s name. Which region the app runs in is chosen per project. Other projects run on a managed virtual private server instead; which one suits yours is decided at the start.

The platform

Railway is a hosting platform that deploys services, workers and databases from a code repository or a Docker image. It groups them into projects with separate environments, a private network between services and usage-based billing.

Railway or Vercel?

The short version: Vercel is built around websites and front ends, with server code in short functions. Railway is built around long-running processes. If your app has queue workers, bots or websocket servers, those need a process that stays up, which points to Railway or a server of your own. Plenty of projects use both: the site on one, the workers on the other.

Other reasons to look elsewhere

High, steady load can make a fixed-size server you manage cheaper, in exchange for doing the upkeep yourself. Data residency or compliance rules should be checked against the regions on offer before choosing.

Questions to ask a team hosting on Railway

  1. Whose account holds the project, and can you get admin access?
  2. Which region runs the app, and how far is it from your users?
  3. How is a release tested in staging and promoted to production?
  4. What sends an alert when a service crashes or usage jumps?

Railway pitfalls

  • Sleeping services. Railway can put inactive services to sleep to save usage. Leave that setting off for workers and bots that must stay connected.
  • A database treated as someone else’s problem. A platform database still needs a tested restore plan; the PostgreSQL page covers it.
  • Usage that grows quietly. Set usage alerts at project start, before the first surprising invoice.

An app with workers and a database

Tell us what it does and roughly how many people will use it. Our web apps service covers the build, and we deploy it to a Railway account you own.