management MCP/CLI cannot migrate workspace compute provider (canvas can) #64
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Gap
The canvas can migrate a workspace's compute provider across clouds (AWS ↔ Hetzner ↔ GCP), but the management MCP server and CLI cannot. This is a real capability gap: an operator driving the platform through the MCP/CLI has no way to trigger or observe a cross-cloud provider migration.
update_workspaceexposes the workspace tier but has no provider field, so there is no existing path to change a workspace's compute provider through these tools.Control-plane contract to wrap (CP-admin auth)
Start a migration —
POST /cp/admin/workspaces/:id/migrate-provider→
202 { "status": "migration_started", "workspace_id": "…", "from": "aws", "to": "hetzner" }tois required; one ofaws|hetzner|gcp.fromis required by CP; one ofaws|hetzner|gcp(must differ fromto).confirm:trueis mandatory — a real migration mutates two clouds; without it CP returns 400.from_instance_idis required by CP for non-AWS (Hetzner/GCP) sources; optional for AWS (CP resolves the real instance from EC2 tags).Read status —
GET /cp/admin/workspaces/:id/migrate-provider(alias…/migration-status)→
200 { "migration": { "state", "from_provider", "to_provider", "detail", … }, "terminal": <bool> }States:
snapshotting → provisioning_target → target_healthy → retiring_source → completed(terminal also includesfailed,rolled_back).404when the workspace has never been migrated.Proposed fix
migrate_workspace_provider(inputs:workspace_id,to[required],from?,confirm?,from_instance_id?) andget_workspace_migration_statustools, wired through the existing CP-admin HTTP-client + tool-registration pattern.molecule workspace migrate-provider --to <p> [--from <p>] <workspace_id>and amigration-statussubcommand via the existingcpAdminClient()helper.Follow-up PRs will close this issue.