Container

Wait for a container

Changed on

Block until a container stops, then returns the exit code.

post/containers/{id}/wait

Request

  • Base URL
    /v1.57 (relative, and the document was published on a file host, not at the API’s origin)
  • Auth
    none declared

Path parameters

idstring required

ID or name of the container

Query parameters

condition'not-running' | 'next-exit' | 'removed'

Wait until a container state reaches the given condition.

Defaults to not-running if omitted or empty.

Response

The container has exit.

StatusCodeinteger required

Exit code of the container

Changes

    • breaking

      removed the media type application/json for the response with the status

    • info

      api tag Container added

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • breaking

      for the query request parameter condition, default value not-running was removed

    • info

      api tag Container removed

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status