clockworklabs / clockworklabs/SpacetimeDB

Railway Deployment Config Issues

Open Beginner friendly
#5,587 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
25.2k
Forks
1.1k
Avg merge
2d 7h
Merged PRs (30d)
46

Description

I've just deployed a STDB C# (.NET 10 AoT) module to the Railway platform using the steps described in the docs.

THE ISSUE:
I noticed after deployment that the module would not use the volume it created at /stdb and would instead store data in the ephemeral storage of the service.

Due to this, each time I would redeploy the service in Railway, I would loose all my data (Including the module itself).
This would also cause the server to crash since the STDB module is not intended to be stored like this.

THE FIX:
I found that if I:

  • Append --data-dir /stdb to the custom start command
  • Set the service permission variable (RAILWAY_RUN_UID=0)
    It would then correctly use the /stdb volume attached to the service.

I'm not sure if the docs need to be updated to include these details?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Railway deployment guide at https://spacetimedb.com/docs/how-to/deploy/railway and compare its custom start command and volume permission instructions with the reported working setup. Done means the guide documents using --data-dir /stdb and setting RAILWAY_RUN_UID=0 so deployments retain module data on the attached volume.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
cloud, documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
75/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.