deploy-preview

deploy-preview is a skill for Claude Code, Codex from xvirobotics/metaskill. It costs 26 tokens per session (585 once invoked), scanned A, original, MIT.

A local deployment preview workflow that builds Docker images, starts the application with Docker Compose, checks service health, and runs database migrations.

In plain words
What is it for?
Use it to build a Docker-based preview, start the local services, confirm they are running, and apply the database schema changes.
Why use it?
It lets you test the complete application stack locally before merging, including its containers and database setup.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/xvirobotics/metaskill/deploy-preview
Any agent
npx skills add xvirobotics/metaskill --skill deploy-preview
Clone the repo
git clone --depth 1 https://github.com/xvirobotics/metaskill

Made for: Claude Code, Codex.

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 deploy-preview

README.md
[![agentmods](https://agentmods.dev/badge/skills/xvirobotics/metaskill/deploy-preview.svg)](https://agentmods.dev/skills/xvirobotics/metaskill/deploy-preview)
Your own site
<a href="https://agentmods.dev/skills/xvirobotics/metaskill/deploy-preview"><img src="https://agentmods.dev/badge/skills/xvirobotics/metaskill/deploy-preview.svg" alt="Measured on agentmods" height="20"></a>
Per session 26 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 585 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
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 $0.00026 $0.00585
Opus 5 $0.00013 $0.00293
Sonnet 5 $0.00005 $0.00117
Haiku 4.5 $0.00003 $0.00059

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

Security

Grade A, and why

deploy-preview scanned grade A 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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -sf http://localhost:3000/api/health || echo "HEALTH CHECK FAILED"
Origin

Copies of this mod

1 near-identical copy found in the catalogue:

examples/fullstack-web/.claude/skills/deploy-preview/SKILL.md · 103 lines

How it starts

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

You are a deployment preview agent. Your job is to build and launch a local preview environment using Docker, then verify it is healthy.

Current State

Current branch: !git branch --show-current Git status: !git status --short

Deployment Steps

Step 1: Verify Docker is Available

docker --version && docker compose version

If Docker is not available, report that Docker must be installed and stop.

Step 2: Stop Any Existing Preview

docker compose -f docker-compose.yml down --remove-orphans 2>/dev/null || true

Step 3: Build Docker Images

Build the application image using the multi-stage Dockerfile:

docker compose -f docker-compose.yml build --no-cache

If the build fails, report the full error output. Common issues: missing files in build context (check .dockerignore), npm install failures, TypeScript compilation errors.

Step 4: Start Services

docker compose -f docker-compose.yml up -d

Wait for services to be healthy:

echo "Waiting for services to start..."
sleep 5
docker compose -f docker-compose.yml ps

Step 5: Run Database Migrations

docker compose -f docker-compose.yml exec -T app npx prisma migrate deploy

If migrations fail, report the error. Common issues: database not ready yet (may need longer wait), migration conflicts.

Step 6: Health Check

Verify the application is responding:

curl -sf http://localhost:3000/api/health || echo "HEALTH CHECK FAILED"

If the health check fails, inspect the logs:

docker compose -f docker-compose.yml logs --tail=50 app

Step 7: Report

## Preview Deployment Results

**Branch:** [branch name]
**Status:** RUNNING / FAILED at [step]

### Services
| Service | Status | Port |
|---------|--------|------|
| app | running/stopped | 3000 |
| db | running/stopped | 5432 |
| client | running/stopped | 5173 |

### Access URLs
- API: http://localhost:3000/api
- Frontend: http://localhost:5173
- Health: http://localhost:3000/api/health

### Cleanup
To stop the preview environment:
docker compose -f docker-compose.yml down

Read the full file on GitHub · 103 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 · 103 lines · 26 tokens per session scan A ec6f97c6063a

Subscribe to this mod's changes

deploy-preview is a skill published in the GitHub repository xvirobotics/metaskill (67 stars, last pushed 6mo ago), licensed MIT. It adds 26 tokens to every session and 585 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

deploy-preview

Build Docker images and launch a local preview environment with docker-compose. Use to test the full stack locally before merging.

morganmuli/metaskill · 26 tokens

manage-mounts

Configure which host directories agent containers can access. View, add, or remove mount allowlist entries. Triggers on "mounts", "mount allowlist", "agent access to directories", "container mounts".

nanocoai/nanoclaw · 47 tokens

johnny-suede-design

Suede Labs AI full-stack surface builder that runs design, copy, and visual QA as one pass: landing pages, brand surfaces, product UI, dashboards, campaigns, launch pages, and reference-to-target restyles (suedify). Use when a build needs layout and words together, when a redesign or launch surface has to ship end to…

JasonColapietro/suede-creator-skills · 179 tokens

suede-code-review

Suede Labs AI findings-only code review with full context: changed files, callers, contracts, and deploy surface. Covers TypeScript, React, Next.js, database, Swift/iOS, OWASP, accessibility, SEO, observability, commit hygiene, and deploy risk, ranked P0-P3 with file:line evidence and a fix path. Use when asked to…

JasonColapietro/suede-creator-skills · 191 tokens

suede-social

Suede-owned organic social strategy and content discipline. Use when planning platform mix, posts, threads, cross-platform calendars, repurposing, listening, engagement, or cadence for a founder or brand account. NOT FOR: Instagram-specific account audits, Reels, carousels, Stories, or daily Instagram loops (use…

JasonColapietro/suede-creator-skills · 108 tokens

voice-preserving-line-edit

Context-aware line edit that strips generic AI writing patterns without flattening the author's voice, plus a findings-only audit mode that names issues instead of rewriting. Applies contextual rules rather than blanket bans on adverbs, passive voice, and punctuation, and locks facts, numbers, quotes, code, links, and…

JasonColapietro/suede-creator-skills · 159 tokens