---
title: "Move this environment's Compose stack to another node. Nothing runs yet: the next deployment stops the stack on its current home (`docker compose down`, volumes kept there) and starts it on the new node with empty volumes. Redeploy to complete the move."
method: POST
path: "/projects/{project_id}/environments/{environment_id}/compose-placement/move"
tags: ["Compose"]
---

# Move this environment's Compose stack to another node. Nothing runs yet: the next deployment stops the stack on its current home (\`docker compose down\`, volumes kept there) and starts it on the new node with empty volumes. Redeploy to complete the move.

`POST /projects/{project_id}/environments/{environment_id}/compose-placement/move`

## Request

- Base URL: `/api` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/projects/{project_id}/environments/{environment_id}/compose-placement/move`
- Auth: HTTP bearer

## Path parameters

- `project_id` integer, required
- `environment_id` integer, required

## Request body

- MoveComposeStackRequest: Move a Compose stack to another node.
  - `acknowledge_data_loss` boolean: The stack starts on the new node with empty volumes; the data on its current home is kept there but not copied. Must be `true` to move a stack that already has a home.
  - `node_id` integer, required: The node to move the stack to; `0` is the control plane.

## Response `200`

The new placement; redeploy to complete the move

- ComposePlacementResponse: Where a Compose environment's stack lives, for the console.
  - `drift` string, nullable: Why the environment's Target Nodes / Label Selectors no longer describe the home, when they do not.
  - `environment_id` integer, required
  - `home_node_id` integer, nullable: The home node: `0` is the control plane. `None` when not pinned.
  - `home_node_name` string, nullable
  - `home_node_status` string, nullable: The home's state (`active`, `offline`, `draining`, ...). Deployments fail rather than move while the home is not active.
  - `moving_from_node_id` integer, nullable: A move is pending: the node the next deployment stops the stack on (`0` is the control plane).
  - `moving_from_node_name` string, nullable
  - `moving_from_node_status` string, nullable: That node's state. The stack's volumes are there, but it only runs there while the node is `active`.
  - `pinned` boolean, required: Whether the stack has a home yet. `false` until its first deployment reaches `docker compose up` (or a move chose one).
  - `pinned_at` string, date-time, nullable: When the stack was pinned to its home, ISO 8601.
  - `project_id` integer, required

## Other responses

- `400`: Not a Docker Compose project, or data loss not acknowledged
- `401`: Unauthorized
- `403`: Insufficient permissions
- `404`: Environment or node not found
- `409`: The node cannot take the stack, or it already lives there
- `500`: Internal server error

## Changes

- **2026-11-09** `12896146b193`: 6 breaking
  - removed the required property `extensions` from the response with the `400` status
  - removed the required property `extensions` from the response with the `401` status
  - removed the required property `extensions` from the response with the `403` status
  - removed the required property `extensions` from the response with the `404` status
  - …2 more
- **2026-10-28** `c29436f6d27d`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/gotempsh/apis/temps/changes/projects/:project_id/environments/:environment_id/compose-placement/move/post.md)

---

[API](https://skmtc.dev/gotempsh/apis/temps.md) - [All operations](https://skmtc.dev/gotempsh/apis/temps/llms.txt) - [OpenAPI document](https://skmtc.dev/gotempsh/apis/temps/revisions/3b040526eb43?raw)
