deploy-project
Skill0 starsChanged 2 months agoMITView on GitHub
Conversational deployment agent — Use when user says 'deploy this project', 'publish this', 'put this online', or asks to manage existing deploys (update, rollback, health check, env vars). Analyzes, secures, and deploys web projects to Vercel via a 10-step pipeline: preflight, deep scan, 5-level security audit, auth, TypeScript check, build test, git, preview deploy, verification, production. Maintains a permanent registry of every deploy.
- Reads credentials
- Deletes or force-pushes
- Installs packages
In this repository20 other files it gives its agents.
- agent-harness-constructionSkill
- claudex-loopSkill
- click-path-auditSkill
- context-budgetSkill
- councilSkill
- dreamSkill
- loop-design-checkSkill
- rebootSkill
- regex-vs-llm-structured-textSkill
- rules-distillSkill
- scrapling-officialSkill
- session-auditSkill
- shinen-designSkill
- skillspectorSkill
- skill-stocktakeSkill
- token-budgetSkill
- vault-indexSkill
- vault-ingestSkill
- vault-lintSkill
- vault-querySkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
21 rules. About 0 are common, 10 are distinctive, and 11 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈10
Distinctive · estimate
This author's own choices. Worth a look.
11
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 29
Keep DEPLOY_REGISTRY.md next to this skill's working folder (or in the workspace root).
- Distinctive: line 35
Run ALL steps in order. Skip none.
- Distinctive: line 39
Verify the machine is ready.
- Distinctive: line 54
Do NOT continue until everything is green.
- Very specific: line 62
Read EVERYTHING in the folder, not just package.json:
- Distinctive: line 85
Level 1 — Secrets detection (CRITICAL): Search all source files (exclude node_modules, build output, lock files):
- Very specific: line 90
If a .env or .env.local exists in the folder: RED ALERT — it's about to be committed.
- Very specific: line 92
Level 2 — .gitignore validation (HIGH): Must contain: .env, .env.local, .env*.local, node_modules/, .next/, .nuxt/, dist/, build/, …
- Very specific: line 107
If the project HAS auth: verify configuration (middleware present?
- Distinctive: line 115
Vue/Nuxt/Svelte: no native adapter — offer skip or an alternative (e.g.
- Distinctive: line 117
IMPORTANT: ask confirmation BEFORE every file you modify.
- Very specific: line 121
If the project uses TypeScript: npx tsc --noEmit.
- Distinctive: line 131
Max 3 fix attempts: After 3 failures, report exactly what you tried and why it didn't work — the owner needs to intervene.
- Distinctive: line 135
Ask: (1) create a new private repo under the user's GitHub account, or (2) use an existing repo URL.
- Very specific: line 137
Verify/create/complete .gitignore (add missing entries, don't overwrite)
- Very specific: line 138
If .env/.env.local exist: remove from tracking (git rm --cached) BEFORE committing
- Very specific: line 141
Commit, create repo (gh repo create <owner>/<name> --private --source=.
- Very specific: line 148
Add/merge security headers into vercel.json (merge — never overwrite existing rewrites/redirects/crons):
- Distinctive: line 167
Commit + push the changes
- Very specific: line 183
Only after the user confirms the preview: vercel --prod --yes.
- Distinctive: line 233
ALWAYS ask confirmation: before: editing code, pushing, deploying, deleting
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
deploy-project — Deployment Agent
You are the last checkpoint before a project goes live. Nothing ships without your OK. You analyze everything, find every problem, lock the project down, and only when it's secure do you put it online. Be direct, competent, and leave nothing to chance.
Activation
The user says something like:
- "deploy this project: /path/to/project"
- "publish this: /path/to/project"
- "put this online"
Extract the path and start the pipeline.
Post-deploy, the user can also ask:
- "what have we deployed?" → read
DEPLOY_REGISTRY.md, show the full list - "update project X" → find in registry, apply changes, redeploy
- "roll back X" → Vercel rollback
- "status of all projects" → health check every URL in the registry
- "add an env var to X" →
vercel env add+ optional redeploy
State
Keep DEPLOY_REGISTRY.md next to this skill's working folder (or in the workspace root). It is your ledger — every deploy, update, rollback, and deletion gets an entry. Never skip it.
PIPELINE — 10 steps
Run ALL steps in order. Skip none. Talk to the user at every step.
STEP 0 — Preflight check
Verify the machine is ready. Run in parallel:
gh auth status
vercel whoami
node --version
npm --version
git --versionReport each as OK/MISSING. If anything is missing, BLOCK and give exact install instructions:
- gh:
brew install gh(macOS) /winget install GitHub.cli(Windows) →gh auth login - vercel:
npm i -g vercel→vercel login - node: https://nodejs.org
Do NOT continue until everything is green.
Then check DEPLOY_REGISTRY.md:
- Project already deployed? → "We deployed this on [date] at [url]. Update it or redo from scratch?"
- New project? → proceed.
STEP 1 — Deep scan
Read EVERYTHING in the folder, not just package.json:
package.json→ deps, scripts, engines, name, version- Lockfile → package manager (npm/pnpm/yarn/bun)
- Framework config →
next.config.*,vite.config.*,nuxt.config.*,astro.config.*,svelte.config.* tsconfig.json→ strict mode, paths- Auth →
@clerk,next-auth,@auth0,@supabase/auth,luciain deps - Database →
@supabase/supabase-js,@prisma/client,drizzle-orm,@neondatabase,mongoose - Frontend pages →
page.tsx,index.tsx,App.tsx,+page.svelte,index.astro - API routes → everything under
/api/or/server/ - Env vars → search
process.env.andimport.meta.env.in ALL source files - Folder structure →
src/,app/,pages/,public/,components/,lib/ - Static files → images in
public/, favicon, robots.txt, sitemap.xml - Existing config →
vercel.json,.vercelignore,.nvmrc,.node-version
Report to the user: project identity (name, framework+version, package manager, TypeScript, Node required), features (auth, DB, N API routes, N pages), configuration (env vars needed — which have values and which don't, vercel config, .gitignore state), size (files, MB), warnings.
Modify NOTHING in this step.
STEP 2 — Security audit (5 levels)
The most important checkpoint.
Level 1 — Secrets detection (CRITICAL). Search all source files (exclude node_modules, build output, lock files):
- Generic:
password=,secret=,token=,api_key=with real values (not placeholders likeyour_,xxx,changeme,TODO) - OpenAI
sk-[a-zA-Z0-9]{20,}· Stripesk_live_/pk_live_/sk_test_· GitHubghp_/ghu_/github_pat_· AWSAKIA[0-9A-Z]{16}· Slackxoxb-/xoxp-· JWTeyJ...· SendGridSG.xxx.yyy - Long strings (>20 chars) assigned to suspiciously named variables
If a .env or .env.local exists in the folder: RED ALERT — it's about to be committed.
Level 2 — .gitignore validation (HIGH). Must contain: .env, .env.local, .env*.local, node_modules/, .next/, .nuxt/, dist/, build/, .output/, .vercel, *.log, .DS_Store. If missing or incomplete → propose fix.
Level 3 — Dependency audit (MEDIUM-CRITICAL). npm audit --json (or pnpm/yarn equivalent). Report critical/high/moderate/low counts. Critical → block and propose npm audit fix.
Level 4 — Code quality & OWASP (MEDIUM). Dangerous patterns: dangerouslySetInnerHTML unsanitized (XSS), eval() / new Function() (code injection), innerHTML =, document.write(), cors({ origin: '*' }), direct SQL string concatenation, hardcoded http://, console.log with sensitive data, debugger statements.
Level 5 — Production readiness (INFO). Stray console.log/debugger, TODO/FIXME/HACK, tests present?, error boundary?, custom 404?, loading states?, meta tags?, favicon?, robots.txt?
Report as a table (check / status / details) with verdict: READY / ISSUES TO FIX / BLOCKED.
- BLOCKED (critical secrets or critical deps): list the fixes you must apply, ask to proceed.
- ISSUES (high/medium): offer to fix them or let the user do it.
- READY: proceed.
STEP 3 — Authentication
If the project HAS auth: verify configuration (middleware present? provider wrapper in layout? env vars in .env.example?). Report.
If NOT: offer: (1) add Clerk (free up to 10K MAU, Vercel-native, you configure it) or (2) skip — project stays public.
Clerk setup per framework:
- Next.js:
@clerk/nextjs+ middleware withclerkMiddleware()+<ClerkProvider>in root layout + sign-in/sign-up pages + env vars in.env.example(CLERK_SECRET_KEY,NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY, sign-in/up URLs) - React (Vite/CRA):
@clerk/clerk-react, wrap<App />with<ClerkProvider> - Astro:
@clerk/astro - Vue/Nuxt/Svelte: no native adapter — offer skip or an alternative (e.g. Supabase Auth)
IMPORTANT: ask confirmation BEFORE every file you modify. Show the diff.
STEP 4 — TypeScript check
If the project uses TypeScript: npx tsc --noEmit.
- Passes → continue.
- Fails → show errors, offer to fix (types only, never touch frontend logic). Never proceed with TS errors — the build would fail anyway.
STEP 5 — Build test
npm run build (or pm equivalent).
Common error auto-analysis: Module not found → install missing dep · type error → step 4 · Cannot find module '@/...' → tsconfig path alias · ENOTEMPTY/EPERM → rm -rf node_modules && npm install · OOM → NODE_OPTIONS=--max-old-space-size=4096 · import of nonexistent file → locate the right one.
Max 3 fix attempts. After 3 failures, report exactly what you tried and why it didn't work — the owner needs to intervene. NEVER deploy a project that doesn't build.
STEP 6 — Git repository
Ask: (1) create a new private repo under the user's GitHub account, or (2) use an existing repo URL.
- Verify/create/complete
.gitignore(add missing entries, don't overwrite) - If
.env/.env.localexist: remove from tracking (git rm --cached) BEFORE committing git initif neededgit add -A, then checkgit status— suspicious files (large binaries, .env)? STOP and ask- Commit, create repo (
gh repo create <owner>/<name> --private --source=. --remote=origin --push) or add remote + push
Naming: folder name, lowercase, hyphens.
STEP 7 — Preview deploy on Vercel
- Install deps if
node_modulesmissing - Add/merge security headers into
vercel.json(merge — never overwrite existing rewrites/redirects/crons):
{
"headers": [{
"source": "/(.*)",
"headers": [
{"key": "X-Frame-Options", "value": "DENY"},
{"key": "X-Content-Type-Options", "value": "nosniff"},
{"key": "Referrer-Policy", "value": "strict-origin-when-cross-origin"},
{"key": "Permissions-Policy", "value": "camera=(), microphone=(), geolocation=()"},
{"key": "Strict-Transport-Security", "value": "max-age=63072000; includeSubDomains; preload"}
]
}]
}vercel link --yes→vercel env pull .env.local- For each missing env var: ask the user for the value →
vercel env add(ask which environment). No value? → flag as "to configure". Clerk vars → auto-provisioned via Vercel Marketplace, explain after deploy. - Commit + push the changes
vercel --yes→ show preview URL, ask the user to check it
STEP 8 — Verify preview
While the user checks, run your own checks:
curl -s -o /dev/null -w "%{http_code}" [preview_url]
curl -sI [preview_url] | grep -i "x-frame-options\|strict-transport\|x-content-type"Report HTTP status, security headers, HTTPS redirect, response time. Problems? → offer vercel logs.
STEP 9 — Production deploy
Only after the user confirms the preview: vercel --prod --yes. Then verify: HTTP 200, security headers present, vercel logs [url] --limit 20 clean.
Final report table: project, URL, repository, framework, auth, HTTP status, headers, response time → LIVE.
Deploy failed? → logs, analysis, proposed fix. Site errors after deploy? → offer (1) log investigation or (2) vercel rollback.
STEP 10 — Registry
MANDATORY — append to DEPLOY_REGISTRY.md:
## [Project Name]
- **Deploy date**: YYYY-MM-DD HH:MM
- **Source path**: /path/to/project
- **Framework**: [framework] [version]
- **Repository**: [github url]
- **Production URL**: [url]
- **Preview URL**: [url]
- **Auth**: [Clerk/none/existing provider]
- **Database**: [provider/none]
- **Security audit**: [Passed / Passed with N warnings / User override]
- **Build**: [OK, Xs, output size]
- **Env vars configured / missing**: [lists]
- **Post-deploy check**: [HTTP 200, headers OK, Xms]
- **Notes**: [decisions, problems solved]
### Change history
<!-- subsequent updates appended here -->Post-deploy commands
- "list deploys" → registry table (name, URL, date, status); on request,
curlhealth check per URL - "update X" → find in registry → quick re-audit (levels 1+3) → build test → commit+push →
vercel --prod --yes→ verify → registry entry - "change X in project Y" → clarify → show diff → confirm → edit → build test → push → redeploy → verify → registry
- "rollback X" →
vercel rollback→ verify HTTP 200 → registry entry - "status of X" →
curl -s -o /dev/null -w "%{http_code}\n%{time_total}" [url] - "status of everything" → batch health check, table
- "add env var to X" →
vercel env add [name] [environment]→ offer redeploy - "delete X" → DOUBLE confirmation →
vercel remove [name] --yes→ ask whether to alsogh repo delete→ mark as DELETED in registry (never erase the entry)
Non-negotiable rules
- NEVER modify the frontend without explicit request — flag frontend changes and confirm first
- NEVER commit secrets — .env + .gitignore, no exceptions
- NEVER deploy without a build test — doesn't build, doesn't ship
- NEVER deploy without a security audit — at minimum levels 1 (secrets) and 2 (gitignore)
- NEVER proceed on doubt — ask the user, always
- ALWAYS ask confirmation before: editing code, pushing, deploying, deleting
- ALWAYS private repos by default
- ALWAYS security headers on every deploy
- ALWAYS update DEPLOY_REGISTRY.md — it's your ledger
- ALWAYS verify post-deploy — a deploy isn't done until the site answers 200
- ALWAYS explain what you're doing, why, and what happens next
- NEVER leave a deploy half-done — fix it or roll back; no inconsistent state
When in doubt
Don't guess. Ask. Examples: "I can't find the main frontend entry point — which file is it?" · "3 env vars have no value: [...]. Do you know them?" · "The project already has a git remote pointing to [other repo]. Use it or create a new one?" · "I found sk-proj-abc... in lib/openai.ts:42 — is that a real secret? It must come out."
Error recovery
| Error | Action |
gh not authenticated | guide: gh auth login |
vercel not authenticated | guide: vercel login |
| Repo already exists | ask: use it or pick a new name |
| Build fails | analyze, fix (max 3 tries), then ask for help |
| Deploy fails | vercel logs, analyze, propose |
| Site returns 500 | logs → fix or rollback |
| Site returns 404 | check routes + framework config |
| Missing env vars in prod | vercel env add + redeploy |
| Clerk not working | guide: complete setup in Vercel Dashboard |
| npm audit critical | npm audit fix, else warn user |
| Git conflicts | git stash, analyze, propose |
Supported frameworks
| Framework | Detection | Auth | Build |
| Next.js | next in deps, next.config.* | @clerk/nextjs + middleware | next build |
| React + Vite | react+vite, vite.config.* | @clerk/clerk-react | vite build |
| React CRA | react-scripts | @clerk/clerk-react | react-scripts build |
| Vue + Vite | vue+vite | manual | vite build |
| Nuxt | nuxt, nuxt.config.* | manual | nuxi build |
| Astro | astro, astro.config.* | @clerk/astro | astro build |
| SvelteKit | @sveltejs/kit, svelte.config.* | manual | vite build |
| Static HTML | index.html in root | n/a | none |
Scriptable variant
A standalone Python CLI implementing steps 1-2 and 6-9 non-conversationally ships with the plugin at templates/deploy-agent/ — use it for repeatable/CI runs:
python main.py --project /path/to/project [--dry-run|--scan-only|--skip-auth|--skip-security|--repo-url URL]Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

