Prerequisites
- Levelrail installed on the new server and the CLI signed in (
levelrail-cli auth login). - The compose file, and for volumes and databases, shell access to the host that runs it.
Pick a route
What imports automatically (import the file)
What needs a manual step
- Services with only a
build:block are unsupported. Build and push an image, or create the app from its git repository. - Database and volume contents, by the copy steps below.
- Networks,
depends_on, restart policy andcommandoverrides are not mapped. Set what matters on each app. - Hostnames between services. Apps reach managed databases by connection variable, not by the compose service name. Rewrite them with the mapping table in the plan.
What cannot be migrated
- Services without an image (build only).
- The compose network model: services do not share one bridge network by default.
- Anything the file does not say: running data, certificates and host proxy config.
Steps
1
Plan
2
Stage
--only NAME for a subset.3
Copy database data
4
Copy volumes
rsync commands as root on the node that hosts the app.5
Verify and switch
levelrail-cli import cutover rollback --session ID --app NAME.Databases and the downtime window
Full dump and restore with row counts compared, repeatable, source read-only. No incremental sync. Stop the writers (docker compose stop web), run the final copy, start the app here, switch DNS. The window is the final copy time plus a restart. Stateless services with no volumes need no pause. See the downtime table.
Domains and TLS
A plain compose stack usually sits behind your own reverse proxy. Point DNS at the new server or install Levelrail in coexist mode. Lower the TTL to 300 seconds a day ahead and runlevelrail-cli migrate cutover for a go or no-go per domain. See Domains and ingress.