Command Line Tools
wheels deploy rollback
Revert traffic to a previously-deployed version. Finds the containers tagged with the given version on every host, starts them, and asks kamal-proxy to switch traffic back.
Synopsis
Section titled “Synopsis”wheels deploy rollback <version> [--destination=<name>] [--dry-run]| Flag | Description |
|---|---|
<version> | Required positional. The version to roll back to. |
--destination=<name> | Overlay deploy.<name>.yml. |
--dry-run | Print the commands without executing. |
Omitting the version throws DeployMainCli.MissingVersion.
Behavior
Section titled “Behavior”For each role, for each host in sequence: docker start <service>-<role>-<version>, then kamal-proxy deploy to route fresh traffic to the resurrected container.
Success requires the target containers to still exist on each host. wheels deploy prune removes old containers, keeping the 5 most recent per host unless you pass --keep=<n> on the prune command line (there is no deploy.yml key for this — Kamal’s retain_containers: is rejected by the config validator). If a target container has been pruned, the docker start step fails — re-deploy from that sha instead.
Examples
Section titled “Examples”wheels deploy rollback abc1234wheels deploy rollback v1.2.3 --destination=production