Skip to main content
Coolify has the most complete path. You can stage apps, move images that were built on the Coolify host, copy databases with row count checks, and switch each domain with a rollback. Read the migration overview first for the flow and the downtime table. The migration wizard drives the whole flow from the dashboard.

Prerequisites

  • Levelrail installed on the new server, signed in with the CLI (levelrail-cli auth login).
  • A Coolify API token. Use the read:sensitive ability, or secret values come back empty.
  • The Coolify URL reachable from the Levelrail control plane. For a private address, set APP_IMPORT_ALLOW_PRIVATE_NETWORKS=true on the control plane and pass --allow-private.
  • For apps built on the Coolify host: SSH access to it with a login that can run docker (root or the docker group).
  • For databases: a database user on each Coolify database, and a route from the Levelrail node to its port.

What moves

What needs a manual step

  • Database contents are copied by a separate step (below).
  • Volume contents are copied by rsync commands you run.
  • Images built on the Coolify host exist nowhere else. Use the Move images step.
  • Git-built apps do not build by themselves. Connect the repository (with credentials for a private one) and run a build, or let verify do it.
  • Old database hostnames in env vars are only rewritten through a mapping you confirm.
  • Secrets the token could not read are skipped and flagged.
  • Build settings move with migrate coolify: base directory, Dockerfile path, static build command and publish directory, start command, pre and post deployment hooks, and build-time variables (stored as secrets with build access). With --apply, a repository given as a full URL is connected with those settings; a private one still needs credentials.
  • Basic auth, www redirects, preview deployments and common proxy labels (redirectscheme, redirectregex, stripprefix, headers) are translated into ingress settings on --apply: a placeholder basic auth credential (never shown, set the real one with domains basic-auth set), a canonical redirect, forwarder and header rules, and previews on with the default policy (gated when the source used basic auth). Until basic auth is set the app is public, and file mode sets nothing. Unknown label keys stay as manual items with the reason. Apps that shared a custom docker network are listed with their peers; no connection is created automatically.
  • Git webhooks: pass --create-webhooks with --apply to register one push webhook per git-sourced app after it is created. It is off by default because it writes to your git host. A hook is only created when the repository URL is https and its scheme, host and port match an authorized git connection (GitHub App, GitLab, Gitea or Bitbucket), and it goes through the existing apps git-source register-webhook route with your own token. The control plane generates the webhook secret, which is never printed or written to the report. A re-run does not add a second hook. Every app that is skipped gets the reason, and a failure on one app does not stop the others. Without --apply the report lists what would be created and writes nothing to the git host. APP_MIGRATE_WEBHOOK_LIMIT (default 200) caps hooks per run and APP_MIGRATE_REPO_URL_MAX_LEN (default 2048) caps the accepted repository URL length.
  • Multi-server instances: pass --node-map source-server=node,other=node2 to put each app on the named node. An unmapped server keeps its apps on the control plane node with a finding, and an unknown or ambiguous node name stops the run before anything is created. Placement needs a token with the root ability, checked first.
  • Extra ports, raw host port mappings, other custom labels, tags, the Node version pin, webhooks and backup schedules are called out as needs attention or planned items. Nothing is dropped without a row in the report. See the gap report.

What does not move

  • Coolify one-click services are not created as apps. migrate coolify reads each service’s compose file and env, translates its SERVICE_ magic variables and stages the result as compose.yaml under --stage-dir (default ./migrated/compose), with hosts under --domain-suffix. Nothing is deployed. Review the file, then deploy it with levelrail-cli compose deploy. The file and --apply modes stage services. The dry-run and verify reports list them as skipped. See one-click services to Compose. Staging is pending run against a real Coolify instance.
  • Coolify Docker Compose applications (the dockercompose build pack) are staged like one-click services: one compose.yaml under --stage-dir with magic variables and generated secrets resolved, plus stack.env (mode 0600) when env values were requested. A file that sets privileged, host networking, host pid or ipc, cap_add, devices or mounts the Docker socket stays blocked with the same reason a manual compose deploy gives. Compose text and secret values never appear in the report.
  • File storages are copied as app files at their mount path with identical bytes. Unsafe paths (relative, .., backslash, control characters) are refused with the reason. Content is copied only with --include-secret-values (otherwise the report lists each path and size), and a secret-looking file is set through the encrypted store. In file mode they are written under <out-dir>/<app>.files/ with owner-only permissions.
  • TLS certificates, DNS records, deploy history, logs and metrics. Certificates are issued here on first use.
  • ClickHouse, KeyDB and Dragonfly databases are created empty as managed databases, like the other engines. A Dragonfly version is kept only when the source pins a full vX.Y.Z tag, and a KeyDB version only for an exact eqalpha/keydb release tag, otherwise the newest supported one is used. Copy the data with the printed migrate db-copy command, or with the engine’s own dump tool and the restore tools where the copy step does not support the engine.

Exit report and cutover checklist

To leave Coolify completely, start with a dry run. It reads Coolify (GET requests only), creates nothing, and prints one row per resource with its outcome: imported, manual (a person finishes it) or skipped (it will not move, with the reason). It also prints the DNS switch order and an ordered cutover checklist.
After staging, ask the control plane for the same report. Apps that already exist here show as imported, so it doubles as the post-migration verification report:
The dashboard shows the report on the import page (“Exit report”), the API serves it at POST /api/v1/migration/coolify/exit-report and GET /api/v1/migration/apps/sessions/{id}/exit-report, and the read-only MCP tool is get_app_import_exit_report. How to read it:
  • Skipped rows never move on their own. One-click services, engines without a managed equivalent, and backup schedules and S3 storage destinations (with the backups schedule set or backup-targets create command that recreates them) land here. Staged one-click services are written as compose files and still need a deploy.
  • Manual rows are the work list: volume data, database data (with the exact migrate db-copy command), backup schedules of imported databases, webhooks on your code host, a proxy that owns ports 80 and 443.
  • The report says ready_to_retire only when nothing is manual or skipped.
DNS switch order, least risky first:
  1. Stateless apps (no volume, no database). A bad switch loses nothing.
  2. Apps with a volume or a database. Pause writes on the old app, run the last data copy, then switch.
  3. Apps with both. Switch last, one at a time.
Keep Coolify as the fallback:
  • Do not stop or delete anything on Coolify until the app has run a full traffic cycle here.
  • Lower the TTL ahead of time. A rollback restores the previous record (levelrail-cli import cutover rollback) and the old app answers again.
  • For an app with a database, the fallback holds only until the first write lands here. After that, copy the data back before rolling back.
  • Before you delete Coolify, keep a copy of its .env (the APP_KEY decrypts everything it stored) and a dump of its own database.
The audit behind this report, including what is not proven because no real Coolify instance was available, is in the gap report.

Steps

1

Plan

Dashboard: Settings, Import from another platform, “Move apps from Coolify”. CLI:
Every app and database gets a verdict (ready, ready with notes, needs attention, unsupported) with the reason. Nothing is created.
2

Stage

The apps are created stopped and unrouted. The output includes a session id such as appimp-123. Re-running skips what exists. Use --map OLD_DB_HOST=NEW_DB_HOST for hostnames you want rewritten, shown with a masked before and after.
3

Move images built on the Coolify host

It runs docker save over SSH and checks the loaded image by content. The target must be the control plane node for now.
4

Copy databases

For a whole server with many databases, use the Migration hub (same Settings page) or levelrail-cli migrate server --engine postgres --host db.old.example.com --user admin --password-stdin --plan, then --apply.
5

Copy volumes

Run the printed commands as root on the node that hosts the app. Then confirm each volume in the wizard’s Volumes step. For apps brought in with import platform, enter the file and byte counts from both hosts on the checklist instead (levelrail-cli migrate step APP data_verified --volume NAME=SRC_FILES:SRC_BYTES:DST_FILES:DST_BYTES).
6

Verify

Builds or pulls each app, waits for its health check, then stops it again until cutover. Test it with curl --resolve app.example.com:443:NEW_IP https://app.example.com/healthz.
7

Cut over

See domains and TLS and downtime. Roll back with levelrail-cli import cutover rollback --session appimp-123 --app web.
8

Retire Coolify

Stop Coolify only after a full traffic cycle and a checked backup. Download the receipt first: levelrail-cli import apps --session appimp-123 --receipt.

Databases

The copy streams pg_dump, mysqldump or mariadb-dump, mongodump or a Redis RDB snapshot from the source into the managed database, then compares row counts per table. It is safe to repeat: the restore replaces the target in one transaction. The source is only read. Coolify databases often have no published port. The Levelrail node must reach the database host and port. Publish the port in Coolify temporarily (restricted by firewall to the new server) or use the migrate server --container path when the database container runs on the same node.

Downtime window

Pause or put the old Coolify app into maintenance mode before the final database copy, so no write lands after it.

Domains and TLS

  • Lower the TTL a day ahead. levelrail-cli migrate cutover returns go, wait (TTL too high), no-go (not healthy here) or switched per domain.
  • The guided cutover switches a domain by the first method that applies: a connected Cloudflare or Route 53 record (previous value stored for rollback), the managed proxy route, or a record you set by hand followed by import cutover confirm-dns.
  • It then checks the public name and rolls back on its own if that fails within APP_CUTOVER_VERIFY_TIMEOUT (5 minutes).
  • Coolify’s Traefik may own ports 80 and 443. Install Levelrail in coexist mode first, or switch DNS to a new server.

Common problems and fixes

Resume or undo an —apply run

Every migrate coolify --apply run writes a journal: one entry per app with each step (created, git source, node, ingress, previews, secrets, files, webhook) and its outcome. The journal holds names, step states and a fingerprint of each created app. It never holds env values, secrets, tokens, passwords or connection strings. It is written with mode 0600, atomically, and a lock file stops two runs from using it at once. The default path is under ~/.config/<cli>/migrate-journals/; pick one with --journal FILE. The path is printed at the end of the run. If the run stopped half way, continue it with the same flags:
Resume skips steps that are done and retries failed ones. It never creates an app that already exists and was not created by this run, and it leaves an app alone if it changed on the target since the run. To roll the run back:
Undo removes only the apps the journal records as created by that run, newest first, with your own token and the normal delete route, so protected environments and delete confirmations still apply. Apps that existed before the run are never touched. An app deployed since the run is listed and skipped unless you pass --force. An app whose fingerprint is missing or no longer matches (it changed since the run, or the run stopped before recording it) is always skipped unless you name it with --force-app NAME; --force never overrides that. Undo checks each app again right before it deletes it. Apps have no immutable id in the API, so the fingerprint is the app’s shape (image, domains, port, node, volumes and similar, never env values): if someone deletes an app and re-creates one with the same name and shape, undo cannot tell them apart, so read the plan before passing --yes. An app holding volume data is skipped unless you pass --include-data and type the number of such apps to confirm; its volumes are then deleted with it. Undo refuses a journal that is a symlink or sits in a symlinked folder, readable by others, over APP_MIGRATE_JOURNAL_MAX_BYTES (default 4 MiB), written for another control plane, or with a name that is not a valid app name.

Choose to stay if

Coolify already does what you need and your team knows it. Levelrail is the younger project with fewer users, and its migration path has had little time on production data. If you cannot take a write freeze or test a rollback, wait. See the comparison and Coolify alternative.
Last modified on November 10, 2026