deploy-verify
Skill23 starsChanged 2 months agoCC0-1.0View on GitHub
Deploy to staging/preview and prove it works before anything reaches users — runs pre-flight gates (types, tests, env, migrations, build), deploys, smoke-tests the live URL, diagnoses failures, and ends by writing a machine-readable verdict artifact that a release orchestrator can trust. Use for "/deploy-verify", "deploy and test", "deploy to staging", "verify deployment", "pre-flight check". Do NOT use for a plain git push with no verification, or for a production release (use /ship).
- Reads credentials
- Commits and pushes
9 other projects use a version of this.
Adopted by
Most recently taken up by
- kimkon1011/orgiast-claude-rulestheir own version, first seen Nov 8, 2026
- jaywedgeworth22/BotFleettheir own version, first seen Nov 3, 2026
- Simple-With-Us/BotFleettheir own version, first seen Nov 3, 2026
- EtanHey/golemstheir own version, first seen Oct 28, 2026
- jonmumm/skillstheir own version, first seen Oct 21, 2026
- kensaurus/cursor-kenjitheir own version, first seen Oct 1, 2026
Used with
Projects with it also use session-start.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
bitwize-music-studioSkillsession-start
Runs the session startup procedure - verifies setup, loads config and state, checks skill models, and reports project status. Use at the beginning of a fresh session.
Also in 3 projects that use this
Other versions9 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 9
- wolverin0/claude-skills★ 41same name
- kensaurus/cursor-kenji★ 9same name
- kensaurus/skills★ 9same name
- jaywedgeworth22/BotFleet★ 4same name
- Simple-With-Us/BotFleet★ 4same name
- jonmumm/skills★ 2same name
- danielarif26/agentic-os-starter★ 1same name
- EtanHey/golems★ 0same name
- kimkon1011/orgiast-claude-rules★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository8 other files it gives its agents.
- attack-surfaceSkill
- bugfix-pipelineSkill
- deep-researchSkill
- first-principlesSkill
- naming-gateSkill
- shipSkill
- tddSkill
- wrap-upSkill
The file
We split this skill into the rules it gives an agent
12 rules. 0 are common, 8 are distinctive, and 4 are very specific to this project.
0
Common
Most of the 8 edited versions we read keep these.
8
Distinctive
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 24
Step 6's verdict artifact is the contract with
/ship: If you use this skill standalone you can ignore it. - Distinctive: line 42
Read the project META to find:
- Distinctive: line 50
Run all checks and collect into a results table:
- Very specific: line 53
Test suite (DB-safety gate FIRST): Before running any DB-touching test, observe the runtime driver connection host the test process will …
- Very specific: line 72
Secrets scan: Run secrets-leak-detector agent on staged changes
- Distinctive: line 74
GATE: If any CRITICAL check fails (tsc, tests, build), STOP and report.
- Distinctive: line 84
Wait for deployment URL to be live:
- Distinctive: line 112
No error strings in response ("undefined", "ECONNREFUSED", "relation does not exist")
- Distinctive: line 116
If any smoke test fails, check common causes:
- Very specific: line 194
Solution: Check build logs (railway logs / vercel logs).
- Distinctive: line 198
Solution: Wait 60 seconds and retry.
- Distinctive: line 206
Solution: Check if staging has access to all required services (Redis, external APIs, etc.).
“Common” is measured: kept by at least 6 in 10 of the 8 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
/deploy-verify — Deploy and Verify Workflow
Pre-flight checks → deploy to staging/preview → smoke test → diagnose failures → report.
Adapting this to your setup
- "Project META" below means whatever file your setup keeps per-project facts in
— a
*_META.md, aCLAUDE.md, aREADME. The skill needs three things from it: the deploy platform, the staging/preview URL pattern, and the list of endpoints worth smoke-testing. Anything that answers those works. - Platforms (Railway, Vercel, Convex, Replit) are the ones wired here; the detection table is data, not logic — add a row for yours.
- Step 6's verdict artifact is the contract with
/ship. If you use this skill standalone you can ignore it; if you use/ship, do not change the filename shape or the field names —/shipmatches on SHA,run_idand timestamp, and a mismatch is treated as NO-GO by design.
Instructions
Step 0: Project & Platform Detection
Detect from cwd and project META file:
| Signal | Platform | Deploy Method | Preview URL |
railway.toml or Railway in META | Railway | railway up or git push | *.up.railway.app |
vercel.json or .vercel/ | Vercel | vercel deploy | *.vercel.app |
convex/ directory | Convex | npx convex deploy | N/A (backend only) |
| Replit in META | Replit | git push origin main | Replit URL from META |
Read the project META to find:
- Production/staging URLs
- Health check endpoints
- Critical API routes
- Database type (Drizzle / Prisma)
Step 1: Pre-Flight Checks
Run all checks and collect into a results table:
- TypeScript compilation:
npx tsc --noEmit— CRITICAL (must pass) - Test suite (DB-safety gate FIRST): Before running any DB-touching test,
observe the runtime driver connection host the test process will actually use
(resolve
DATABASE_URL/equivalent as the test config injects it — an env-var-presence check fails open; a config can inject a prodDATABASE_URLdirectly). If that host is a forbidden prod host (rlwy.net, a Railway-internal host, the project's prod DB) with no safeTEST_DATABASE_URL/override actually wired into the test process, ERROR — do not run (name the cause). When invoked by/shipwith a recipe, run the recipe's exactverify_beforecommand; never fall back to an auto-detectednpm test. Then run the framework's tests — CRITICAL (Standalone behavior change: this gate may now ERROR a standalone/deploy-verifywhose tests connect to a forbidden prod host — a safety win, not a regression.) - Environment variables: Compare
.env.examplekeys vs deployed config- Railway:
railway variables - Vercel:
vercel env ls - Convex:
npx convex env ls
- Railway:
- Database migration status:
- Drizzle:
npx drizzle-kit check - Prisma:
npx prisma migrate status
- Drizzle:
- Build:
npm run buildorbun run build— CRITICAL - Secrets scan: Run
secrets-leak-detectoragent on staged changes
GATE: If any CRITICAL check fails (tsc, tests, build), STOP and report. For non-critical (env gaps, pending migrations), warn and ask user whether to proceed.
Step 2: Deploy to Staging/Preview
Based on detected platform:
- Railway:
railway up --environment stagingor push to PR branch for PR environment - Vercel:
vercel deploy(automatically creates preview URL, output includes it) - Convex:
npx convex deploy --preview <branch-name>
Wait for deployment URL to be live:
# Poll every 5s, max 120s
for i in $(seq 1 24); do
STATUS=$(curl -s -o /dev/null -w "%{http_code}" "$DEPLOY_URL")
if [ "$STATUS" = "200" ] || [ "$STATUS" = "301" ] || [ "$STATUS" = "302" ]; then
break
fi
sleep 5
doneStep 3: Smoke Test
For each endpoint, run a curl check:
# Health check
curl -s -w "\n%{http_code} %{time_total}s" "$DEPLOY_URL/api/health"
# Critical API endpoints (from META)
curl -s -w "\n%{http_code} %{time_total}s" "$DEPLOY_URL/api/..."Validate:
- Response status code (expect 200)
- Response body has expected fields (basic JSON structure)
- Response time is reasonable (<5s)
- No error strings in response ("undefined", "ECONNREFUSED", "relation does not exist")
Step 4: Diagnose Failures
If any smoke test fails, check common causes:
| Symptom | Likely Cause | Diagnostic Command |
| 502/504 | DNS not propagated or service not ready | Wait 60s, retry |
| 500 with "undefined" | Missing env var | railway variables / vercel env ls |
| 500 with "relation does not exist" | Unmigrated DB | prisma migrate status / drizzle-kit check |
| 500 with stack trace | Runtime error | railway logs --tail 50 / vercel logs <url> |
| 429 | Rate limiting | Check API quotas |
| Connection refused | Service didn't start | Check build logs |
Step 5: Report
Output a markdown report:
## Deploy Verification Report
**Project:** [name] | **Platform:** [Railway/Vercel/...] | **URL:** [deployed URL]
### Pre-Flight
| Check | Status | Details |
|-------|--------|---------|
| TypeScript | PASS/FAIL | N errors |
| Tests | PASS/FAIL | N tests, N failures |
| Env Vars | PASS/WARN | Missing: KEY_NAME |
| Migrations | PASS/WARN | N pending |
| Build | PASS/FAIL | time |
| Secrets | PASS/WARN | N issues |
### Smoke Tests
| Endpoint | Status | Time | Notes |
|----------|--------|------|-------|
| /api/health | 200 | 340ms | OK |
| /api/... | 500 | 1.2s | Missing JWT_SECRET |
### Diagnosis (if failures)
[Root cause and fix recommendation]Step 6: Verdict artifact (deterministic machine contract for /ship)
The markdown report above is for humans. /ship must not grep narrative prose (an
LLM report is not a machine contract). So also end by writing a deterministic
verdict file artifact, written atomically (temp file → mv/rename), to a path
unique per PR/session so a parallel session can't read a stale or clobbered one.
When invoked by /ship, it passes --run-id=<nonce> — use THAT exact run-id in the
path so /ship reads exactly this file (a caller can't learn a callee-chosen nonce);
standalone, generate your own run-id:
<scratchpad-or-tmp>/deploy-verify-verdict.<repo>.<pr-or-branch>.<run-id>.json{
"verdict": "PASS|WARN|FAIL|ERROR",
"verified_sha": "<full SHA that was verified>",
"branch": "<branch>",
"run_id": "<unique nonce for this run>",
"timestamp": "<ISO-8601>",
"gates": { "tsc": "PASS", "tests": "PASS", "env": "WARN", "migrations": "PASS", "build": "PASS", "secrets": "PASS" },
"smoke": { "<endpoint>": "PASS|FAIL" },
"notes": "<short>"
}verdict rules: PASS only if every CRITICAL gate passed and smoke is green;
WARN if green but with env-gap / pending-migration; FAIL if a CRITICAL gate or
smoke failed; ERROR if verification couldn't complete (incl. the DB-safety gate
firing). /ship trusts a PASS only after asserting verified_sha == the SHA it
is about to ship AND timestamp is within a recency window AND the path is this
run's; stale/mismatched/missing → NO-GO. Standalone runs write it too (harmless;
useful for audit).
Troubleshooting
Deployment timed out
Cause: Build taking too long or deployment stuck.
Solution: Check build logs (railway logs / vercel logs). Increase poll timeout if build is large.
Health check returns 502
Cause: DNS propagation delay or service still starting. Solution: Wait 60 seconds and retry. For Railway, check service health in dashboard.
500 after deploy but works locally
Cause: Environment mismatch — different env vars, missing DB migration, or wrong Node version.
Solution: Compare railway variables with local .env. Check prisma migrate status. Verify Node version in runtime config.
Tests pass locally but endpoint fails
Cause: Tests mock external dependencies that fail in staging. Solution: Check if staging has access to all required services (Redis, external APIs, etc.).
Examples
Example 1: a Railway-hosted web app
User says: /deploy-verify
- Detects Railway from cwd + the project's META
- Pre-flight: tsc ✅, vitest ✅, env vars ✅, drizzle check ✅, build ✅
- Deploy:
git pushtriggers Railway, polls PR environment URL - Smoke:
/api/health200,/api/items200,/api/search200 - Report: all green
Example 2: a Vercel app with a pending migration
User says: "deploy and verify"
- Detects Vercel from cwd
- Pre-flight: tsc ✅, tests ✅, build ✅, prisma: 1 pending migration ⚠️
- Asks user: "1 pending Prisma migration. Apply before deploy?"
- User confirms → runs migration → continues deploy
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.

