Skip to main content
Glama
ConnorBoetig-dev

Unrestricted Development MCP Server

docker_images

List Docker images with filtering options to manage container environments and identify available images for development workflows.

Instructions

List Docker images

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filterNoFilter images (e.g., "reference=node:*")
allNoShow all images (default hides intermediate)
formatNoOutput formattable
cwdNoWorking directory

Implementation Reference

  • The main handler function that constructs and executes the 'docker images' command using the shared executeDockerCommand helper, based on input arguments.
    export async function dockerImages(args: z.infer<typeof dockerImagesSchema>): Promise<ToolResponse> { const allFlag = args.all ? '-a' : ''; const filterFlag = args.filter ? `--filter "${args.filter}"` : ''; const formatFlag = args.format === 'json' ? '--format "{{json .}}"' : '--format "table {{.Repository}}\\t{{.Tag}}\\t{{.ID}}\\t{{.Size}}"'; return executeDockerCommand(`docker images ${allFlag} ${filterFlag} ${formatFlag}`.trim(), args.cwd); }
  • Zod schema for validating input arguments to the docker_images tool.
    export const dockerImagesSchema = z.object({ filter: z.string().optional().describe('Filter images (e.g., "reference=node:*")'), all: z.boolean().optional().default(false).describe('Show all images (default hides intermediate)'), format: z.enum(['table', 'json']).optional().default('table').describe('Output format'), cwd: z.string().optional().describe('Working directory') });
  • MCP tool metadata definition for 'docker_images' included in the exported dockerTools array used for tool listing.
    { name: 'docker_images', description: 'List Docker images', inputSchema: { type: 'object', properties: { filter: { type: 'string', description: 'Filter images (e.g., "reference=node:*")' }, all: { type: 'boolean', default: false, description: 'Show all images (default hides intermediate)' }, format: { type: 'string', enum: ['table', 'json'], default: 'table', description: 'Output format' }, cwd: { type: 'string', description: 'Working directory' } } } },
  • src/index.ts:475-478 (registration)
    Dispatch logic in the main MCP CallToolRequest handler that routes calls to docker_images by validating arguments and invoking the handler function.
    if (name === 'docker_images') { const validated = dockerImagesSchema.parse(args); return await dockerImages(validated); }

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/ConnorBoetig-dev/mcp2'

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