MCP ExplorerExplorer

Mcp Containerd

@jokemanfireon a year ago
31 MIT
FreeCommunity
AI Systems
# Using mcp to Manage containerd (In Development)

Overview

What is Mcp Containerd

mcp-containerd is an MCP server implemented using the RMCP (Rust Model Context Protocol) library, designed to manage the CRI (Container Runtime Interface) of Containerd.

Use cases

Use cases for mcp-containerd include managing container lifecycles (creation, deletion, status checks), handling pod sandboxes, and performing image operations such as pulling and deleting images.

How to use

To use mcp-containerd, ensure you have a Rust development environment and Containerd installed. Build the project using ‘cargo build --release’ and run it with ‘cargo run --release’. The server will connect to the default endpoint ‘unix:///run/containerd/containerd.sock’.

Key features

Key features of mcp-containerd include support for all CRI operations of Containerd, runtime service interfaces, image service interfaces, and a structured service architecture with version, runtime, and image services.

Where to use

mcp-containerd can be used in cloud-native environments, container orchestration platforms, and any application requiring efficient management of containerized applications via Containerd.

Content

MCP Containerd

This is an MCP server implemented using the RMCP (Rust Model Context Protocol) library for operating Containerd’s CRI interfaces.

Features

  • Implements an MCP server using the RMCP library
  • Supports all Containerd CRI interface operations
  • Provides Runtime Service interfaces
  • Provides Image Service interfaces

Prerequisites

  • Rust development environment
  • Containerd installed and running
  • Protobuf compilation tools

Building

cargo build --release

Running

cargo run --release

By default, the service will connect to the unix:///run/containerd/containerd.sock endpoint.

Using with simple-chat-client

The simple-chat-client allows you to interact with the MCP Containerd service:
simple-chat-client has moved to simple-chat-client

Example interaction:

> please give me a list of containers
AI: Listing containers...
Tool: list_containers
Result: {"containers":[...]}

> please give me a list of images
AI: Here are the images in your containerd:
Tool: list_images
Result: {"images":[...]}

Service Structure

The MCP server includes the following main components:

  • version service: Provides CRI version information
  • runtime service: Provides container and Pod runtime operations
  • image service: Provides container image operations

CRI Interfaces

Runtime Service

  • Create/Stop/Delete Pod Sandbox
  • Create/Start/Stop/Delete containers
  • Query Pod/container status
  • Execute commands in containers

Image Service

  • List images
  • Get image status
  • Pull images
  • Delete images
  • Get image filesystem information

Configuration

Currently using default configuration. Future versions will support customizing connection parameters through configuration files.

License

Apache-2.0

Tools

No tools

Comments

Recommend MCP Servers

View All MCP Servers