build-image

build-image is a command for Claude Code from vinnie357/claude-skills. It costs 25 tokens per session (731 once invoked), scanned C, original, MIT.

A command that builds an OCI container image for Claude Code from the plugin's Dockerfile template. OCI images are portable packages used to run software in containers.

In plain words
What is it for?
Use it to create a Claude Code image for SandboxTemplates, either for local testing or for storage in a container registry.
Why use it?
It removes the repeated work of preparing the build context, running the image build, optionally publishing it to a registry, and checking that it starts.

Command for Claude Code

Written for Claude Code: argument-hint in frontmatter. Also seen: mentions Claude Code.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the agent-sandboxing plugin — 7 skills, 6 commands shipped together

Good fit Use it to create a Claude Code image for SandboxTemplates, either for local testing or for storage in a container registry.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add vinnie357/claude-skills
Claude Code
/plugin install agent-sandboxing

Made for: Claude Code.

Or install agent-sandboxing, the plugin that ships this one along with the rest of its 7 skills, 6 commands.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for build-image

README.md
[![agentmods](https://agentmods.dev/badge/commands/vinnie357/claude-skills/build-image/github.svg)](https://agentmods.dev/commands/vinnie357/claude-skills/build-image)
Your own site
<a href="https://agentmods.dev/commands/vinnie357/claude-skills/build-image"><img src="https://agentmods.dev/badge/commands/vinnie357/claude-skills/build-image/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for build-image

Your own site · 80×15
<a href="https://agentmods.dev/commands/vinnie357/claude-skills/build-image"><img src="https://agentmods.dev/badge/commands/vinnie357/claude-skills/build-image.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 25 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 731 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00025 $0.00731
Opus 5 $0.00013 $0.00365
Sonnet 5 $0.00005 $0.00146
Haiku 4.5 $0.00003 $0.00073

Measured 5d ago against content hash e1ffd1321165, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade C, and why

build-image scanned grade C with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Recursive force deletehighDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

rm -rf $BUILD_DIR
plugins/tools/agent-sandboxing/commands/build-image.md · 82 lines

How it starts

The opening of the file, as written. The whole thing — 82 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Build the workload image that SandboxTemplates reference.

Skills to load

  • /agent-sandboxing:claude-code-on-sandbox
  • /core:mise
  • /core:anti-fabrication

Steps

1. Resolve build context

The plugin ships:

  • templates/Dockerfile.claude-code — mise-driven Dockerfile, non-root agent user, BuildKit cache mounts.
  • templates/mise.toml.claude-code — pins node = "lts" + claude-code = "latest" via the mise registry short name. Do not switch to npm:@anthropic-ai/claude-code — the short name is the convention here.

Stage them into a build context:

BUILD_DIR=$(mktemp -d)
cp <CLAUDE_PLUGIN_ROOT>/templates/Dockerfile.claude-code $BUILD_DIR/Dockerfile
cp <CLAUDE_PLUGIN_ROOT>/templates/mise.toml.claude-code $BUILD_DIR/mise.toml

2. Build

Pick --load for local-only iteration, --push for registry publication. Default to --load if neither is specified.

REGISTRY=${REGISTRY:-ghcr.io/$USER}
TAG=${TAG:-$(date +%Y%m%d)}

docker buildx build \
  --tag ${REGISTRY}/claude-code:${TAG} \
  ${PUSH:+--push} ${LOAD:+--load} \
  --file $BUILD_DIR/Dockerfile \
  $BUILD_DIR

3. Verify

docker run --rm ${REGISTRY}/claude-code:${TAG} --version

Expected: a Claude Code version string (the image's CMD is --print --output-format json, so passing --version overrides it).

If the image returns no output or fails, inspect the Dockerfile — likely the mise install step couldn't reach the npm registry from inside the build, or the node = "lts" resolved to an unsupported version.

4. Update the SandboxTemplate

Once the image is built and pushed, edit the installed SandboxTemplate to use it:

kubectl set image sandboxtemplate/claude-code-kata claude=${REGISTRY}/claude-code:${TAG}

Or re-apply from the plugin template with placeholders substituted:

sed -e "s|REGISTRY/claude-code:TAG|${REGISTRY}/claude-code:${TAG}|" \
  <CLAUDE_PLUGIN_ROOT>/templates/SandboxTemplate.kata.yaml | kubectl apply -f -

Read the full file on GitHub · 82 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 82 lines · 25 tokens per session scan C e1ffd1321165

Subscribe to this mod's changes

build-image is a command published in the GitHub repository vinnie357/claude-skills (25 stars, last pushed 3d ago), licensed MIT. It adds 25 tokens to every session and 731 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it C with 1 finding (recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.