buildx_du
Reports BuildKit cache disk usage to identify large caches in need of pruning. Accepts an optional builder override.
Instructions
Report BuildKit cache disk usage as a list of records.
A large cache can easily generate more output than MAX_CLI_OUTPUT_BYTES; if that happens the
captured stdout is truncated and this tool drops the final (partial) record before parsing.
For an exhaustive accounting on a busy builder, run docker buildx du --format '{{json .}}'
on the host directly. Reclaim the cache with buildx_prune (system_df covers daemon-side
disk, not builder cache).
Raises RemoteFailureError if the CLI call fails.
Args: builder: Override the active builder
Returns:
list: One dict per cache record (parsed from --format '{{json .}}')
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "buildx_du"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| builder | No |