agentleFS
sandraschisandraschi/podman-mcp/llms-full.txt

podman-mcp

llms.txt1 starsChanged 53 days agoMITView on GitHub

Version: 3.5.3 | Ports: 11112 (frontend) / 11113 (backend + MCP /mcp) Stack: FastMCP 3.5 · Python 3.12+ · React 19 · Vite · Tailwind · Zustand Dual transport: stdio for Claude Desktop, HTTP for webapp/opencode. The same FastMCP singleton serves both — no separate server process. run_server.py entry point detects MCP_PORT env var: if set → HTTP mode; if absent → stdio mode. All tools follow the portmanteau pattern (discriminator-based operations). Each tool is decorated with @mcp.tool() and @check_podman_available.

The file

We split this llms-full.txt into the rules it gives an agent

2 rules. About 0 are common, 0 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    All tools follow the portmanteau pattern (discriminator-based operations).

    line 22
  2. Very specific:

    All operations require project_path (directory containing the compose file).

    line 93

≈ “Common” is an estimate: at least 1 in 5 of the 4,067 llms.txt files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
llms-full.txt
# podman-mcp — Full LLM Reference

**Version**: 3.5.3 | **Ports**: 11112 (frontend) / 11113 (backend + MCP /mcp)
**Stack**: FastMCP 3.5 · Python 3.12+ · React 19 · Vite · Tailwind · Zustand

## Architecture

```
LLM Agent (Claude/Cursor/opencode)
    ├── stdio JSON-RPC → FastMCP (podman-mcp) → podman CLI (native/WSL2) → Podman Machine
    └── HTTP REST → FastAPI Bridge (:11113) → same pipeline

React Webapp (:11112) → FastAPI (:11113) → podman CLI → Podman Machine
```

Dual transport: stdio for Claude Desktop, HTTP for webapp/opencode. The same
FastMCP singleton serves both — no separate server process. `run_server.py` entry
point detects `MCP_PORT` env var: if set → HTTP mode; if absent → stdio mode.

## MCP Tools — Complete Reference

All tools follow the portmanteau pattern (discriminator-based operations).
Each tool is decorated with `@mcp.tool()` and `@check_podman_available`.

### manage_containers
`tools/containers.py` — Container lifecycle, introspection, and resource management.

Operations: `list`, `inspect`, `start`, `stop`, `restart`, `delete`, `create`, `logs`, `stats`, `exec`, `files`, `resources`

| Op | Parameters | Description |
|----|-----------|-------------|
| `list` | — | All containers (running + stopped) |
| `inspect` | `container_id` | Low-level JSON config |
| `start` / `stop` / `restart` | `container_id` | Lifecycle control |
| `delete` | `container_id` | Force-remove (`podman rm -f`) |
| `create` | `image` (+ `container_name`, `ports`, `volumes`, `env`, `cmd_args`) | Run new container in background |
| `logs` | `container_id` (+ `tail_lines=100`) | Recent stdout/stderr |
| `stats` | `container_id` | Instant CPU/memory/IO metrics |
| `exec` | `container_id`, `exec_cmd` | Run command inside container |
| `files` | `container_id`, `file_op` (`list`/`read`/`write`), `container_path` (+ `file_content`) | In-container file I/O |
| `resources` | `container_id`, `resource_op` (`get`/`set`), `cpu_limit`, `memory_limit` | Get/set CPU & memory limits |

### manage_pods
`tools/pods.py` — Kubernetes-style pod management (Podman-unique, no Docker equivalent).

Operations: `list`, `inspect`, `create`, `start`, `stop`, `delete`

| Op | Parameters | Description |
|----|-----------|-------------|
| `list` | — | All pods |
| `inspect` | `pod_id` | Low-level pod config |
| `create` | `pod_name`, `ports`, `volumes` | Create pod namespace |
| `start` / `stop` | `pod_id` | Pod lifecycle |
| `delete` | `pod_id` | Force-remove pod |

### manage_images
`tools/images.py` — Image registry operations.

Operations: `list`, `inspect`, `pull`, `delete`, `build`, `search`

| Op | Parameters | Description |
|----|-----------|-------------|
| `list` | — | Local images |
| `inspect` | `image_name` | Image metadata |
| `pull` | `image_name` (+ `timeout`) | Pull from registry |
| `delete` | `image_name` | Force-remove image |
| `build` | `build_context`, `dockerfile`, `tag` | Build from Dockerfile/Containerfile |
| `search` | `search_term` | Search registry |

### manage_system
`tools/system.py` — Machine lifecycle, volumes, networks, systemd generation, prune.

Operations: `status`, `info`, `machine_list`, `machine_init`, `machine_start`, `machine_stop`, `prune`, `generate_systemd`, `volume_list`, `volume_create`, `volume_delete`, `network_list`, `network_create`, `network_delete`

| Op | Parameters | Description |
|----|-----------|-------------|
| `status` | — | CLI health, machine list, rootless flag, container/image counts |
| `info` | — | Full `podman info --format json` |
| `machine_list` | — | VM environments |
| `machine_init` | — | Scaffold new VM |
| `machine_start` | — | Boot VM |
| `machine_stop` | — | Halt VM |
| `prune` | — | `podman system prune -f` |
| `generate_systemd` | `container_id` or `name` | Generate systemd unit from container |
| `volume_list` / `_create` / `_delete` | `name` (for create/delete) | Volume CRUD |
| `network_list` / `_create` / `_delete` | `name` (for create/delete) | Network CRUD |

### manage_compose
`tools/compose.py` — Multi-container stack orchestration via `podman compose`.

Operations: `up`, `down`, `ps`, `logs`, `build`, `config`, `debug`

All operations require `project_path` (directory containing the compose file).
Uses `--workdir` global option for directory independence.

| Op | Parameters | Description |
|----|-----------|-------------|
| `up` | `project_path` | Build and start stack in background |
| `down` | `project_path` (+ `volumes`) | Stop and remove stack |
| `ps` | `project_path` | List compose services |
| `logs` | `project_path` | Aggregated logs (last 100 lines) |
| `build` | `project_path` | Pre-build images |
| `config` | `project_path` | Resolve final compose config |
| `debug` | `project_path` | Diagnose compose setup (paths, version, file existence) |

### manage_backup
`tools/backup.py` — Image/container/volume/compose save and restore. **DESTRUCTIVE annotation**.

Operations: `save_image`, `load_image`, `export_container`, `import_container`, `save_volume`, `load_volume`, `save_compose`, `list_backups`

| Op | Parameters | Description |
|----|-----------|-------------|
| `save_image` | `name`, `output_path` | `podman save -o <path> <image>` |
| `load_image` | `output_path` (+ `tag`) | `podman load -i <path>` |
| `export_container` | `name`, `output_path` | Export container filesystem to tar |
| `import_container` | `output_path`, `name` (+ `tag`) | Import tar as image |
| `save_volume` | `name`, `output_path` | Backup volume to tar.gz via alpine helper |
| `load_volume` | `name`, `output_path` | Restore volume from tar.gz |
| `save_compose` | `name` (project path), `output_path` | Snapshot compose project metadata |
| `list_backups` | `output_path` | List backup archives in directory |

### manage_migrate
`tools/migrate.py` — Docker↔Podman porting. **No Docker installation required** — uses podman CLI for everything.

Operations: `docker_compose_to_podman`, `podman_compose_to_docker`, `scan_docker_artifacts`, `migrate_image`, `compatibility_check`, `dockerfile_to_containerfile`, `export_for_docker`

| Op | Parameters | Description |
|----|-----------|-------------|
| `docker_compose_to_podman` | `source_path` (+ `output_path`) | Convert docker-compose.yml for Podman |
| `podman_compose_to_docker` | `source_path` (+ `output_path`) | Reverse conversion |
| `scan_docker_artifacts` | `source_path` (optional) | Find compose files, Dockerfiles, images |
| `migrate_image` | `image_name` (+ `new_name`) | Pull Docker Hub image, re-tag for Podman |
| `compatibility_check` | `source_path` | Check compose for unsupported features (deploy, secrets, configs, service_healthy) |
| `dockerfile_to_containerfile` | `source_path` | Copy Dockerfile → Containerfile |
| `export_for_docker` | `image_name` (+ `output_path`) | Export as docker-archive for `docker load -i` |

### manage_agentic
`tools/agentic.py` — Multi-step autonomous workflows. **DESTRUCTIVE annotation**. Always runs with `dry_run=True` by default.

Operations: `deploy_compose`, `cleanup`, `diagnose`, `rollback`, `health_sweep`

| Op | Parameters | Description |
|----|-----------|-------------|
| `deploy_compose` | `project_path` (+ `dry_run`) | Validate → pull → up, step-by-step reporting |
| `cleanup` | `dry_run` | Prune stopped containers, dangling images, volumes, networks |
| `diagnose` | `project_path` (optional) | Scan exited/restarting/unhealthy containers |
| `rollback` | `project_path` (+ `dry_run`) | Down → up cycle |
| `health_sweep` | `dry_run` | Check health of all running containers, restart unhealthy |

### manage_health
`tools/health.py` — READ_ONLY annotation. Container health analysis and system overview.

Operations: `container_analyze`, `system_overview`, `recommendations`

| Op | Parameters | Description |
|----|-----------|-------------|
| `container_analyze` | `container_id` | Restart count, OOM killed, exit code, log error scan, memory pressure |
| `system_overview` | — | Aggregate counts, restart loops, disk usage |
| `recommendations` | — | Prioritized fix suggestions (high/medium/low) |

### podman_shutdown
`fleet_surface.py` — Orderly server shutdown (confirm-gated).

| Op | Parameters | Description |
|----|-----------|-------------|
| (confirm=False) | — | Returns "pass confirm=true" hint, no exit |
| (confirm=True) | — | Replies 200, exits the process ~500 ms later |

### Prefab cards (`fleet_surface.py`, all `@mcp.tool(app=True)`)

`podman_containers_card` (all_states), `podman_pods_card`,
`podman_machine_status_card`, `podman_images_card` (limit), `podman_system_info_card`.

### Prompts and resources (`fleet_surface.py`)

Prompts: `podman_deploy_stack` (stack_name), `podman_machine_health_check`.
Resources: `resource://podman-mcp/skills`, `resource://podman-mcp/capabilities`.

## REST API Endpoints

| Method | Path | Purpose |
|--------|------|---------|
| GET | `/api/health` | Health check |
| GET | `/api/dashboard` | Aggregate: containers + images + system + pods |
| GET | `/api/containers` | Container list |
| GET | `/api/pods` | Pod list |
| GET | `/api/images` | Image list |
| GET | `/api/volumes` | Volume list |
| POST | `/api/volumes/create` | Create volume |
| POST | `/api/volumes/delete` | Delete volume |
| GET | `/api/networks` | Network list |
| POST | `/api/networks/create` | Create network |
| POST | `/api/networks/delete` | Delete network |
| GET | `/api/system` | System status + info + disk |
| GET | `/api/compose/projects` | Scan for compose files |
| GET | `/api/compose/ps` | Compose process status |
| POST | `/api/compose/up` | Compose up |
| POST | `/api/compose/down` | Compose down |
| GET | `/api/compose/logs` | Compose logs |
| POST | `/api/chat` | Chat (Ollama/LM Studio/agentic) |
| GET | `/api/logs` | Activity log query |
| GET | `/api/logs/stats` | Log stats |
| GET | `/api/logs/export` | Log export (JSON/CSV) |
| DELETE | `/api/logs` | Clear logs |
| GET | `/api/v1/diagnostics` | CUA smoke test diagnostics |
| GET | `/api/skills` | Prompt + tool names for skill-first chat |
| GET | `/api/status` | Running status: uptime, tool_count |
| GET | `/api/llm/discover` | Local provider probe (alias of providers) |
| GET | `/api/llm/models` | Model list per provider |
| GET | `/api/llm/onboarding` | Starter facts + recommended path |
| POST | `/api/llm/chat` | Chat completion (alias of `/api/chat`) |
| POST | `/api/shutdown` | Orderly exit (~500 ms, for launcher restarts) |
| POST | `/api/tools/call` | Execute a runnable tool: {"tool", "params"} (9 manage_*; cards/shutdown refused) |
| GET | `/api/events?since=24h&limit=200` | Engine event inbox (newest-first; `engine: down` + message when unreachable) |
| POST | `/api/podman/recover` | Restart Podman machine |
| GET | `/api/capabilities` | Page flags, tool_count, LLM providers |
| GET | `/api/tools` | Tool names |
| GET | `/api/llm/providers` | LLM provider discovery (Ollama/LM Studio) |

## Environment Variables

| Variable | Default | Description |
|----------|---------|-------------|
| `PODMAN_CMD` | auto-detect | Podman CLI path override |
| `MCP_TRANSPORT` | `stdio` | Transport: stdio / http / sse |
| `MCP_HOST` | `127.0.0.1` | HTTP bind address |
| `MCP_PORT` | `11113` | HTTP port |
| `MCP_PATH` | `/mcp` | HTTP endpoint path |
| `MCP_USER` / `MCP_PASS` | — | Basic auth for /api/chat |
| `PODMAN_MCP_SAMPLING_BASE_URL` | — | LLM endpoint for ctx.sample() |
| `PODMAN_MCP_SAMPLING_MODEL` | — | Model for ctx.sample() |
| `OLLAMA_BASE_URL` | `http://localhost:11434` | Ollama endpoint |
| `LMSTUDIO_BASE_URL` | `http://localhost:1234` | LM Studio endpoint |
| `LOG_LEVEL` | `WARNING` | Log level |
| `PODMAN_MCP_LOG_MAX_ENTRIES` | `1000` | Ring buffer size |
| `MCP_BRIDGE_URLS` | — | Comma-separated MCP proxy URLs |

## Project Structure

```
podman-mcp/
├── src/
│   ├── server.py                  # FastAPI app + CORS + lifespan
│   ├── customization/             # uvicorn entry wrapper
│   ├── podmanmcp/
│   │   ├── mcp_instance.py        # FastMCP singleton
│   │   ├── tool_registration.py   # Tool module imports
│   │   ├── podman_context.py      # CLI resolution + subprocess
│   │   ├── fleet_surface.py       # Prefab cards + prompts
│   │   └── tools/                 # 9 portmanteau tools
│   │       ├── containers.py
│   │       ├── pods.py
│   │       ├── images.py
│   │       ├── system.py
│   │       ├── compose.py
│   │       ├── backup.py
│   │       ├── migrate.py
│   │       ├── agentic.py
│   │       └── health.py
│   └── podman_mcp/
│       ├── web.py                 # REST endpoints
│       ├── config.py              # Sampling config
│       ├── auth.py                # Basic auth
│       ├── activity_log.py        # Ring buffer logger
│       └── llm/                   # LLM provider manager
├── web_sota/                      # React/Vite frontend
│   └── src/
│       ├── App.tsx                # Router (13 routes)
│       ├── pages/                 # 13 page components
│       ├── components/layout/     # Sidebar, Topbar, AppLayout
│       ├── lib/api.ts             # API_BASE
│       └── store/connection.ts    # Zustand connection state
├── justfile
├── pyproject.toml
└── uv.lock
```

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.