Skip to content
Safe recovery of previous deployments without executing scheduled jobs
jpxav
OP

17 days ago

Hello Railway team,

I'm reviewing recovery procedures for a service that runs scheduled jobs. Before making any changes, I'd like to clarify how Railway handles historical deployment images and recovery.

I have seven questions:

  1. How can I verify whether a previous deployment's exact container image is still available under Railway's image retention policy?
  2. Is there a way to retrieve or verify an immutable image reference without triggering a deployment?
  3. When using Redeploy on a historical deployment, does Railway reuse the original image or rebuild it from the original source?
  4. Is there a supported way to prepare a historical deployment for recovery without executing its original startup command or scheduled job?
  5. How are startup commands, cron schedules, environment variables and persistent volumes handled during rollback or redeployment?
  6. Can a previous deployment image be prepared with an inert startup configuration before any application process executes?
  7. When rollback is unavailable, what recovery approach does Railway recommend to ensure a controlled return to a known version without unintentionally executing scheduled workloads?

I'm looking for documentation and supported procedures only. I do not want to trigger a deployment or modify a running service as part of this inquiry.

Thank you for your guidance.

Solved

3 Replies

Railway
BOT

17 days ago

Image availability is shown by the Rollback option. After a deployment is removed, we keep its image for your plan's retention period, which is 72 hours on Hobby. If a previous deployment still shows Rollback in its menu, the image is still available. Once that period has passed, the option no longer appears.

Rollback and Redeploy work differently. A rollback within the retention period restores the original image, settings and variables as a new deployment, with no rebuild. Outside that period, Redeploy rebuilds the image from the deployment's original source code and uses that deployment's original variables. It does not reuse the original image. See Deployment Actions.

Both actions create a new deployment that runs with that deployment's configuration. That means its start command runs as soon as the new deployment starts. We can't confirm any supported way to stage a historical image or get an image reference without deploying, or to swap in an inert start command before the restored process starts.

To keep scheduled work from firing unexpectedly, keep in mind that both Rollback and Redeploy bring back the original settings and variables, not only the code.


Status changed to Awaiting User Response Railway • 17 days ago


jpxav
OP

17 days ago

Thank you for the response.

The main safety requirement remains unresolved.

Before attempting recovery, could a Railway team member clarify whether there is an officially supported procedure to:

  1. Verify the availability of an exact historical deployment image without rebuilding or deploying it.
  2. Recover that image with an inert startup command, ensuring the original scheduled workload cannot execute.
  3. Prevent restoration of historical startup commands, schedules or credentials until they are explicitly reviewed and approved.

If Railway does not support this workflow, please confirm that limitation explicitly.

We are seeking documentation and guidance only. We will not perform a test redeployment or modify a production service to investigate this.

Thank you.


Status changed to Awaiting Railway Response Railway • 17 days ago


Railway
BOT

17 days ago

To answer your three points directly: we don't have a supported procedure for this workflow.

On availability, the only indicator we offer is whether the Rollback option still appears on that deployment. It stays visible during your plan's image retention period (72 hours after removal on Hobby). We don't offer a separate way to inspect or verify an immutable image reference without deploying it.

On an inert startup, a rollback restores the previous image, settings and all variables as a new deployment that starts right away. We don't support swapping in a different start command, schedule or variables beforehand, so the restored configuration runs as soon as the deployment starts.

On review before restoration, neither Rollback nor Redeploy has a review or approval step for historical start commands, schedules or credentials. Both bring back that deployment's original configuration and variables, as described in Deployment Actions. Redeploy also rebuilds from the original source rather than reusing the original image.


Status changed to Awaiting User Response Railway • 17 days ago


Railway
BOT

10 days 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 • 10 days ago


Welcome!

Sign in to your Railway account to join the conversation.

Loading...