This document outlines the specification for tools within the Containerization module that are integrated with the Model Context Protocol (MCP). These tools are defined in mcp_tools.py and exposed via the @mcp_tool decorator.
Check the availability of container runtimes (Docker, Kubernetes) and related components (registry, security scanner, optimizer) on the current system.
codomyrmex.container_runtime_status
No parameters required.
| Field Name | Type | Description | Example Value |
|---|---|---|---|
status |
string |
"ok" |
"ok" |
runtimes |
object |
Availability of each runtime | See below |
runtimes.docker |
boolean |
Docker manager available | true |
runtimes.kubernetes |
boolean |
Kubernetes integration available | false |
runtimes.registry |
boolean |
Container registry available | false |
runtimes.security_scanner |
boolean |
Security scanner available | false |
runtimes.optimizer |
boolean |
Image optimizer available | false |
This tool does not raise errors; it always returns runtime availability flags.
- Idempotent: Yes
Build a Docker container image from a Dockerfile path with a specified name and tag.
codomyrmex.container_build
| Parameter Name | Type | Required | Description | Example Value |
|---|---|---|---|---|
image_name |
string |
Yes | Name for the image | "myapp" |
dockerfile_path |
string |
No | Path to Dockerfile directory (default: ".") |
"./docker" |
tag |
string |
No | Image tag (default: "latest") |
"v1.0" |
| Field Name | Type | Description | Example Value |
|---|---|---|---|
status |
string |
"ok" or "error" |
"ok" |
image |
string |
Full image name with tag | "myapp:v1.0" |
result |
any |
Build result from DockerManager | ... |
- Returns
{"status": "error", "error": "Docker manager not available"}if Docker is not installed. - Returns
{"status": "error", "error": "<message>"}on build failures.
- Idempotent: No. Rebuilds the image each time.
List running Docker containers managed by the local Docker daemon.
codomyrmex.container_list
No parameters required.
| Field Name | Type | Description | Example Value |
|---|---|---|---|
status |
string |
"ok" or "error" |
"ok" |
containers |
array |
List of running container objects | [...] |
- Returns
{"status": "error", "error": "Docker manager not available"}if Docker is not installed.
- Idempotent: Yes
Run a security vulnerability scan on a container image using the built-in ContainerSecurityScanner.
codomyrmex.container_security_scan
| Parameter Name | Type | Required | Description | Example Value |
|---|---|---|---|---|
image |
string |
Yes | Container image to scan | "python:3.11-slim" |
| Field Name | Type | Description | Example Value |
|---|---|---|---|
status |
string |
"ok" or "error" |
"ok" |
image |
string |
Scanned image name | "python:3.11-slim" |
scan_result |
object |
Vulnerability scan results | {...} |
- Returns
{"status": "error", "error": "Security scanner not available"}if scanner is not installed.
- Idempotent: Yes
- Parent: Project Overview
- Module Index: All Agents
- Documentation: Reference Guides
- Home: Root README