4 months ago
When I update my custom config-as-code at repo root (e.g. railway-my-backend.toml) as a commit on my branch, then end up locally rebasing and squashing my commits against my main
, often the Railway deployment won't pick up the changes.
My 'workaround' is to manually update (in the UI) the "Config-as-Code"->"Railway config file" to an empty value, apply it, manually deploy, then change the "Config-as-Code"->"Railway config file" back to "railway-my-backend.toml"), which seems to pick up the changes.
In other words, there seems to be some caching or reuse of the config file in the Railway backend that breaks normal workflows. How can we make sure the "Config as code" is always refreshed with the latest from the repo, vs using a stale copy?
8 Replies
4 months ago
An example 'change' would be - change the content of the preDeployCommand
or healthCheckTimeout
in the [deploy]
TOML section.
These are not picked up (in the above rebase flow) until I manually remove the config-as-code in the Web UI (delete the railway-my-backend.toml
reference and save via check mark) and then add it back in, and redeploy.
My expectation is that when I push to the branch, Railway picks up the change to this file. I can tell its picking up other changes, since it does attempt to redeploy and so forth, and I'm using the standard Github integration, nothing custom or fancy.
4 months ago
Hey there Josh,
By any chance is the config as code file in your .gitignore?
- Angelo
Status changed to Awaiting User Response Railway • 5 months ago
angelo-railway
Hey there Josh,By any chance is the config as code file in your .gitignore?- Angelo
4 months ago
I can confirm there is no offending line in the .gitignore:
```
.env
build
dist
node_modules
*.tsbuildinfo
.turbo
```
Status changed to Awaiting Railway Response Railway • 5 months ago
4 months ago
Hello!
We're acknowledging your issue and attaching a ticket to this thread.
We don't have an ETA for it, but, our engineering team will take a look and you will be updated as we update the ticket.
Please reply to this thread if you have any questions!
4 months ago
Noted, I have gone ahead and created a ticket that tracks this bug. Will report back.
Status changed to Awaiting User Response Railway • 4 months ago
4 months ago
❌ The internal ticket Stale Config as Code regardless of the change to railway.toml
has been marked as canceled.
4 months ago
Is there a reason the internal ticket was cancelled? Are you unable to reproduce?
1. In a project with PR environments enabled, create a PR in Github. Ensure the code uses *.toml
config-as-code for the service(s) you are deploying
Confirm the initial deployment/environment creation works
Create a few commits, push to Github
Locally, rebase the commits, force push to Github
The services do not properly redeploy
Status changed to Awaiting Railway Response Railway • 4 months ago
Status changed to Awaiting User Response Railway • 4 months ago
2 months ago
This thread has been marked as solved automatically due to a lack of recent activity. Please re-open this thread or create a new one if you require further assistance. Thank you!
Status changed to Solved Railway • 2 months ago