container_create
Creates a container from an image without starting it, allowing configuration via extra_kwargs for later manual startup, separating creation from execution.
Instructions
Create a container from an image without starting it.
Use this when you need to configure a container (with extra_kwargs) before its first
start, or want creation and start as separate observable steps. For the common case of
create-then-start-immediately use container_run instead - it does both in one call.
Start the created container with container_start. Common extra_kwargs keys: name
(str), environment (list of "KEY=VAL" or dict), ports (dict, e.g. {"80/tcp": 8080}),
volumes (dict, e.g. {"/host/path": {"bind": "/container/path", "mode": "rw"}}), labels
(dict). For anything else docker-py's ContainerCollection.create accepts, call
docs_lookup(section="containers") rather than guessing a key name.
Args: image: Image to create the container from, e.g. "nginx:alpine" command: Override the image's default command; string or list of strings extra_kwargs: Additional docker-py ContainerCollection.create keyword arguments
Returns: dict: The created container's full inspect payload (not yet running)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| image | Yes | ||
| command | No | ||
| extra_kwargs | No |