Skip to main content
Glama

restart_container

Destructive

Restart a Docker container via container-host-aiops, capturing prior state for audit and allowing dry-run preview.

Instructions

[WRITE][risk=medium] Restart a container (captures prior state for audit).

A restart has no meaningful inverse, so no undo is recorded. Pass dry_run=True to preview.

Args: container_id: Container id or name. timeout: Seconds to wait for graceful stop before killing (default 10). dry_run: If True, preview without restarting. target: Target name from config; omit for the default.

Input Schema

NameRequiredDescriptionDefault
targetNo
dry_runNo
timeoutNo
container_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.0

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true and idempotentHint=false; the description adds genuinely new context: prior state is captured for audit, there is no meaningful inverse so no undo is recorded, and dry_run previews the action. This is meaningful disclosure beyond the structured hints.

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

Conciseness4/5

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

Front-loaded with risk tag and purpose, then a concise behavioral note, then a tidy Args block. Every line earns its place; only slight redundancy in restating default values already in the schema.

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

Completeness4/5

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

No output schema exists, and for a destructive 4-param mutation the description covers the safety profile, undo behavior, preview mechanism, and all parameters. It is complete enough to invoke correctly, missing only explicit routing among sibling lifecycle tools.

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

Parameters4/5

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

With schema description coverage at 0%, the description carries the burden and documents all four parameters: container_id (id or name), timeout (graceful stop window, default 10), dry_run (preview semantics), and target (config name, omit for default). It compensates well for the empty schema descriptions, though no extra format detail is given.

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?

States a specific verb+resource ('Restart a container') and is immediately distinguishable from siblings like stop_container and start_container. The [WRITE][risk=medium] tag reinforces the operation class up front.

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

Usage Guidelines3/5

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

Provides a preview path via dry_run=True, which is useful guidance. However, it never states when to restart vs. alternatives like stop_container+start_container or update_container, nor any preconditions, so usage context is implied rather than explicit.

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