Skip to main content
Glama

docker_run

Execute and manage Docker containers by specifying images, commands, ports, volumes, and environment variables. Supports background execution, resource limits, and automatic removal.

Instructions

Run a Docker container

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
argsNoCommand arguments
commandNoCommand to run in container
cpusNoCPU limit (e.g., "0.5", "2")
detachNoRun container in background
envNoEnvironment variables as key-value pairs
imageYesDocker image to run
interactiveNoKeep STDIN open
memoryNoMemory limit (e.g., "512m", "2g")
nameNoContainer name
networkNoNetwork to connect container to
portsNoPort mappings (e.g., ["8080:80", "3000:3000"])
removeNoRemove container when it exits
restartNoRestart policy (no, on-failure, always, unless-stopped)
ttyNoAllocate a pseudo-TTY
userNoUsername or UID (format: <name|uid>[:<group|gid>])
volumesNoVolume mounts (e.g., ["/host/path:/container/path"])
working_dirNoWorking directory inside container

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/block/vscode-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server