Skip to main content
Glama

container_commit

Create a new Docker image from a container's current filesystem state, capturing manual changes or debugging states for later reuse.

Instructions

Snapshot a container's current filesystem state as a new image.

Useful for capturing a debugging state or saving manual changes made inside a container. For repeatable builds use image_build with a Dockerfile instead; publish the result with image_tag + image_push. The container is paused by default during the snapshot to ensure filesystem consistency — set pause=False only if the container cannot be paused. changes accepts Dockerfile instructions to apply on top of the snapshot, e.g. ["CMD ["python", "app.py"]", "ENV FOO=bar"].

args: id_or_name - Container id or name to snapshot repository - Repository name for the new image, e.g. "myorg/myimage" tag - Tag for the new image (default: "latest") message - Commit message stored in the image metadata author - Author string stored in the image metadata pause - Pause the container during commit for consistency (default True) changes - Dockerfile instructions (CMD, ENV, EXPOSE, etc.) to apply to the image conf - Additional image configuration overrides as a dict returns: dict - The new image's full inspect payload (Id is the new image id)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagNo
confNo
pauseNo
authorNo
changesNo
messageNo
id_or_nameYes
repositoryNo
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the annotations (readOnlyHint=false, destructiveHint=false), the description discloses important runtime behavior: 'The container is paused by default during the snapshot to ensure filesystem consistency — set `pause=False` only if the container cannot be paused.' It also explains the `changes` semantics and states the return value is the full inspect payload containing the new image id. No annotation contradiction exists.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is compact and front-loaded with the core purpose. The first sentence defines the action, the second gives use cases and alternatives, and the third explains pause behavior. The args list is terse but informative, with each parameter receiving a short meaningful phrase. No filler or redundant content is present.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

This is a complex 8-parameter tool with no output schema. The description covers all parameters, explains the pause default and exception, describes the `changes` input format, and states the return type ('dict - The new image's full inspect payload'). It provides enough context for an agent to invoke the tool correctly without additional documentation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Although the input schema has no parameter descriptions (0% coverage), the description's dedicated args list explains every single parameter: id_or_name, repository, tag, message, author, pause, changes, and conf. It even gives an example Dockerfile instruction format for `changes`. This fully compensates for the schema's lack of descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific, unambiguous verb phrase: 'Snapshot a container's current filesystem state as a new image.' It clearly identifies the resource (container) and the outcome (image). The description also differentiates from sibling tools by explicitly recommending `image_build` for repeatable builds, which distinguishes this ad-hoc snapshot workflow from declarative image creation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit guidance on when to use the tool: 'Useful for capturing a debugging state or saving manual changes made inside a container.' It also gives concrete alternative guidance: 'For repeatable builds use `image_build` with a Dockerfile instead; publish the result with `image_tag` + `image_push`.' It additionally explains when to disable pause, giving a clear if-then usage rule.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/L337-org/docker-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server