Provides comprehensive management of Docker infrastructure, including tools for containers, stacks, images, networks, and volumes across multiple host environments.
Enables management of Git-based stacks, allowing for the deployment, synchronization, and configuration of repositories and credentials for containerized applications.
Supports vulnerability scanning of Docker images through integration with security tools like Trivy.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP Dockhandshow me the logs for the nginx container in the production environment"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP Dockhand
An MCP (Model Context Protocol) server that exposes 130+ Dockhand API endpoints as MCP tools. Manage your entire Docker infrastructure through AI assistants.
Dockhand is a Docker management server that connects to multiple Docker hosts via Hawser agents. This MCP server provides full programmatic access to all Dockhand features.
Features
130+ MCP Tools covering all Dockhand API endpoints
Streamable HTTP Transport (MCP Spec 2025-03-26) for Docker container hosting
Session-based Auth with auto-relogin on 401
SSE Support for deploy operations (start, stop, down, restart)
Environment Filter enforced on all container/stack/image/network/volume endpoints
Docker Ready with multi-stage build, non-root user, and health checks
Quick Start
Docker (recommended)
docker run -d \
--name mcp-dockhand \
-p 8080:8080 \
-e DOCKHAND_URL=https://your-dockhand-server.com \
-e DOCKHAND_USERNAME=your-username \
-e DOCKHAND_PASSWORD=your-password \
ghcr.io/strausmann/mcp-dockhand:latestDocker Compose
services:
mcp-dockhand:
image: ghcr.io/strausmann/mcp-dockhand:latest
container_name: mcp-dockhand
restart: unless-stopped
ports:
- "8080:8080"
environment:
- DOCKHAND_URL=https://your-dockhand-server.com
- DOCKHAND_USERNAME=your-username
- DOCKHAND_PASSWORD=your-passwordFrom Source
git clone https://github.com/strausmann/mcp-dockhand.git
cd mcp-dockhand
npm install
npm run build
DOCKHAND_URL=https://your-server.com DOCKHAND_USERNAME=admin DOCKHAND_PASSWORD=secret npm startConfiguration
Variable | Required | Default | Description |
| Yes | - | Dockhand server URL |
| Yes | - | Dockhand username |
| Yes | - | Dockhand password |
| No |
| Port for the MCP server |
| No |
| Log level |
MCP Client Configuration
Claude Desktop / Claude Code
Add to your MCP settings:
{
"mcpServers": {
"dockhand": {
"url": "http://localhost:8080/mcp"
}
}
}Tool Reference
Containers (27 tools)
Tool | Description |
| List all containers in an environment |
| Get container details |
| Docker inspect (full details) |
| Get container logs |
| Get resource usage stats |
| Get running processes |
| Start a container |
| Stop a container |
| Restart a container |
| Pause a container |
| Unpause a container |
| Rename a container |
| Update container settings |
| Create a new container |
| List available shells |
| Browse files inside container |
| Read file from container |
| Create file in container |
| Delete file in container |
| Rename file in container |
| Change file permissions |
| Check for image updates |
| Get pending updates |
| Batch update containers |
| Get container disk sizes |
| Get aggregated stats |
Stacks (21 tools)
Tool | Description |
| List all stacks |
| Get stack details |
| Create and optionally deploy a stack |
| Start a stack (compose up) |
| Stop a stack (compose stop) |
| Restart a stack |
| Take down a stack (compose down) |
| Delete a stack |
| Read compose file |
| Update compose file |
| Read environment variables |
| Update environment variables |
| Read raw .env file |
| Validate env variables |
| Scan filesystem for stacks |
| Adopt an untracked stack |
| Move stack to new path |
| Get stack sources |
| Get base path |
| Get path suggestions |
| Validate a stack path |
Images (9 tools)
Tool | Description |
| List all images |
| Get image details |
| Get image layer history |
| Tag an image |
| Remove an image |
| Pull an image |
| Push an image |
| Vulnerability scan (Trivy/Grype) |
| Export image as tarball |
Environments (18 tools)
Tool | Description |
| List all environments |
| Get environment details |
| Create an environment |
| Update an environment |
| Delete an environment |
| Test connection |
| Test without saving |
| Auto-detect socket |
| Get timezone |
| Set timezone |
| Get update-check settings |
| Set update-check settings |
| Get image prune settings |
| Set image prune settings |
| List notifications |
| Create notification |
| Get notification |
| Delete notification |
Networks (7 tools)
Tool | Description |
| List all networks |
| Get network details |
| Inspect network |
| Create a network |
| Remove a network |
| Connect container |
| Disconnect container |
Volumes (9 tools)
Tool | Description |
| List all volumes |
| Get volume details |
| Inspect volume |
| Browse files in volume |
| Read file from volume |
| Release browse session |
| Clone a volume |
| Export volume |
| Remove volume (destructive) |
Git Stacks (15 tools)
Tool | Description |
| List Git-based stacks |
| Get Git stack details |
| Deploy a Git stack (SSE) |
| Sync with remote repo |
| Test Git connection |
| Get env files |
| Trigger webhook |
| Get webhook details |
| List Git credentials |
| Create Git credential |
| Get credential details |
| Update credential |
| Delete credential |
| List Git repositories |
| Create repository config |
Dashboard & Activity (8 tools)
Tool | Description |
| Get dashboard statistics |
| Get display preferences |
| Set display preferences |
| Get activity feed |
| Container activity |
| Activity events |
| Activity statistics |
| Merged logs from containers |
Auth & Hawser (12 tools)
Tool | Description |
| Check session status |
| List auth providers |
| Get auth settings |
| Create OIDC provider |
| Get OIDC provider |
| Test OIDC provider |
| Create LDAP provider |
| Get LDAP provider |
| Test LDAP provider |
| List Hawser tokens |
| Create Hawser token |
| Revoke Hawser token |
Audit (4 tools)
Tool | Description |
| Get audit log |
| Get audit event types |
| Audit data by user |
| Export audit log |
Notifications (8 tools)
Tool | Description |
| List notifications |
| Create notification |
| Get notification |
| Update notification |
| Delete notification |
| Test notification |
| Test without saving |
| Trigger test event |
Registries (10 tools)
Tool | Description |
| List registries |
| Add registry |
| Get registry details |
| Update registry |
| Delete registry |
| Set as default |
| Search registry |
| Get catalog |
| Get image from registry |
| Get image tags |
System & Settings (19 tools)
Tool | Description |
| Server health |
| Database health |
| Host information |
| System information |
| Disk usage |
| List system files |
| Read system file |
| Changelog |
| Dependencies |
| General settings |
| Update settings |
| Theme settings |
| Update theme |
| Scanner settings |
| Update scanner |
| License info |
| Activate license |
| Prometheus metrics |
| Prune all resources |
Users, Roles & Preferences (20 tools)
Tool | Description |
| List users |
| Create user |
| Get user details |
| Update user |
| Delete user |
| MFA status |
| Enable MFA |
| Disable MFA |
| Get user roles |
| Set user roles |
| List roles |
| Create role |
| Get role |
| Update role |
| Delete role |
| Get own profile |
| Update own profile |
| Get favorites |
| Set favorites |
| List config sets |
Schedules (9 tools)
Tool | Description |
| List schedules |
| Get settings |
| Update settings |
| Execution history |
| Execution details |
| Get schedule |
| Run immediately |
| Enable/disable |
| Toggle system schedule |
Auto-Update (3 tools)
Tool | Description |
| Get all auto-update settings |
| Get container auto-update |
| Set auto-update policy |
Important Notes
Environment ID is Required
Most Docker resource endpoints (containers, stacks, images, networks, volumes) require an environmentId parameter. This maps to the ?env=<id> query parameter in the Dockhand API. Without it, endpoints return empty arrays.
SSE Responses
Deploy operations (start, stop, down, restart, compose update with restart) return Server-Sent Events. The MCP server automatically parses these and returns the final result.
Authentication
The server uses session-based cookie authentication. It automatically:
Logs in on first request
Stores the session cookie in memory
Re-authenticates on 401 responses
Handles session timeout (24h)
Development
# Install dependencies
npm install
# Type check
npm run typecheck
# Build
npm run build
# Run in development mode
DOCKHAND_URL=https://your-server.com \
DOCKHAND_USERNAME=admin \
DOCKHAND_PASSWORD=secret \
npm run devLicense
This server cannot be installed
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.