[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M792EFVV5V092CKR3XTNDZ1T":3,"skill-same:01M792EFVV5V092CKR3XTNDZ1T":61},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":26,"commitSha":27,"skillDirectory":28,"forksCount":14,"repositoryHtmlUrl":29,"repositoryHomepageUrl":30,"ownerHtmlUrl":31,"ownerBlogUrl":32,"ownerDescription":33,"updatedAt":34,"install":35,"resources":48},"01M792EFVV5V092CKR3XTNDZ1T","deployment",null,"Ship it: platform config for Vercel, Netlify, Fly, Railway, AWS, env secrets, checklists, and rollback. Use when deploying applications to cloud environments.","poorvith-mp\u002Fskills-developer","poorvith-mp","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F277478855?v=4","01M78Z5K0YH1Z3PX815PGQ96ND","Poorvith M P","01M792ACSFXT45RJ69SSGKTVJN",0,"MIT","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Fdeployment\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: deployment\nlast_reviewed: 2026-09-06\ngroup: Ship and run\ndescription: >-\n  Ship it: platform config for Vercel, Netlify, Fly, Railway, AWS, env secrets, checklists, and\n  rollback. Use when deploying applications to cloud environments.\n---\n\n# Deployment\n\nDeployments fail on environment drift, schema mismatches, and unverified secrets. A reliable deployment pipeline specifies target platform configurations explicitly, manages environment secrets strictly through platform vaults, verifies database migration forward-compatibility, and guarantees automated rollback in under 60 seconds.\n\n## 1. Platform Configuration Archetypes\n\n### A. Vercel (`vercel.json`)\nUsed for Next.js, SvelteKit, and frontend\u002Fserverless architectures:\n```json\n{\n  \"buildCommand\": \"npm run build\",\n  \"outputDirectory\": \".next\",\n  \"framework\": \"nextjs\",\n  \"regions\": [\"iad1\"],\n  \"cleanUrls\": true,\n  \"headers\": [\n    {\n      \"source\": \"\u002F(.*)\",\n      \"headers\": [\n        { \"key\": \"X-Content-Type-Options\", \"value\": \"nosniff\" },\n        { \"key\": \"X-Frame-Options\", \"value\": \"DENY\" }\n      ]\n    }\n  ]\n}\n```\n- **CLI Commands**: `vercel deploy` (preview), `vercel deploy --prod` (production promote).\n- **Environment Scope**: Segregate variables between Development, Preview, and Production.\n\n### B. Netlify (`netlify.toml`)\nUsed for static sites, Jamstack, and Netlify Edge functions:\n```toml\n[build]\n  command = \"npm run build\"\n  publish = \"dist\"\n\n[[redirects]]\n  from = \"\u002F*\"\n  to = \"\u002Findex.html\"\n  status = 200\n\n[[headers]]\n  for = \"\u002F*\"\n  [headers.values]\n    Strict-Transport-Security = \"max-age=31536000; includeSubDomains; preload\"\n```\n- **CLI Commands**: `netlify deploy`, `netlify deploy --prod`.\n\n### C. Fly.io (`fly.toml`)\nUsed for full-stack Node.js, Go, Python, and containerized long-running services:\n```toml\napp = \"production-app\"\nprimary_region = \"iad\"\n\n[build]\n  dockerfile = \"Dockerfile\"\n\n[http_service]\n  internal_port = 3000\n  force_https = true\n  auto_stop_machines = \"stop\"\n  auto_start_machines = true\n  min_machines_running = 1\n\n[[http_service.checks]]\n  grace_period = \"10s\"\n  interval = \"15s\"\n  method = \"GET\"\n  timeout = \"5s\"\n  path = \"\u002Fhealthz\"\n```\n- **CLI Commands**: `fly launch`, `fly secrets set KEY=VALUE`, `fly deploy`, `fly releases rollback`.\n\n### D. Railway (`railway.json` \u002F Nixpacks)\nUsed for microservices, Redis, PostgreSQL, and background worker queues:\n```json\n{\n  \"$schema\": \"https:\u002F\u002Frailway.com\u002Frailway.schema.json\",\n  \"build\": {\n    \"builder\": \"NIXPACKS\",\n    \"buildCommand\": \"npm run build\"\n  },\n  \"deploy\": {\n    \"startCommand\": \"node dist\u002Findex.js\",\n    \"healthcheckPath\": \"\u002Fhealthz\",\n    \"healthcheckTimeout\": 100,\n    \"restartPolicyType\": \"ON_FAILURE\",\n    \"restartPolicyMaxRetries\": 10\n  }\n}\n```\n- **CLI Commands**: `railway up`, `railway variables set KEY=VALUE`.\n\n### E. Cloudflare Pages & Workers (`wrangler.toml`)\nUsed for edge compute, global APIs, and static assets with serverless bindings:\n```toml\nname = \"edge-api\"\nmain = \"src\u002Findex.ts\"\ncompatibility_date = \"2026-01-01\"\n\n[vars]\nENVIRONMENT = \"production\"\n\n[[kv_namespaces]]\nbinding = \"CACHE\"\nid = \"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\"\n```\n- **CLI Commands**: `wrangler secret put KEY`, `wrangler deploy`.\n\n### F. AWS (App Runner \u002F ECS Fargate \u002F CDK)\nUsed for enterprise multi-tenant architectures and private VPC deployments:\n- Inject secrets via AWS Secrets Manager or SSM Parameter Store using IAM task roles (`arn:aws:iam::...`). Never bake `.env` into container layers.\n- App Runner: define `apprunner.yaml` with build and run stages, health checks, and auto-scaling rules (min 1, max 10 instances).\n- ECS Fargate: configure Blue\u002FGreen deployments using AWS CodeDeploy with automatic rollback triggered on CloudWatch 5xx alarm breaches.\n\n## 2. Zero-Downtime Migration & Rollback Discipline\n- **Expand\u002FContract Database Pattern**:\n  1. *Phase 1 (Expand)*: Add nullable column or new table. Deploy migration.\n  2. *Phase 2 (Dual Write)*: Deploy application code writing to both old and new schemas.\n  3. *Phase 3 (Backfill)*: Asynchronously backfill historical data.\n  4. *Phase 4 (Contract)*: Deploy code reading exclusively from new schema; drop old column in a subsequent release.\n- **Rollback Runbook**:\n  - Keep previous deployment artifact\u002Fimage digest tagged (`:v3.0.0-previous`).\n  - Automated platform rollback: `fly releases rollback`, `vercel rollback [deployment-url]`, or AWS ECS task definition reversion.\n\n## Critical Rules\n1. Never run destructive database migrations (`DROP COLUMN`, `ALTER TABLE ... RENAME`) in the same deployment as application code changes.\n2. Production builds must run from committed git SHAs, never uncommitted local dirty states.\n3. Every production service must expose an unauthenticated, lightweight `\u002Fhealthz` endpoint verifying process vitality and database connectivity.\n\n## Verification Checklist\n- [ ] Target platform configuration file (`vercel.json`, `fly.toml`, `netlify.toml`, `railway.json`, `wrangler.toml`) committed and validated.\n- [ ] Environment secrets populated in platform vault; no secrets committed to git or exposed in client bundles.\n- [ ] Health check endpoint (`\u002Fhealthz`) verified returning HTTP 200 before cutover.\n- [ ] Database migrations tested in staging for forward-compatibility.\n- [ ] Instant rollback mechanism (CLI command or container rollback) verified and tested.\n\n## Anti-Patterns\n- NEVER run database migrations inside the container startup script (`CMD`); execute migrations as a separate pre-deploy step or release phase.\n- NEVER deploy to production with `latest` Docker tags; pin immutable content digests (`sha256:...`).\n- NEVER store production encryption keys or credentials in repository `.env.production` files.\n","# Deployment\n\nDeployments fail on environment drift, schema mismatches, and unverified secrets. A reliable deployment pipeline specifies target platform configurations explicitly, manages environment secrets strictly through platform vaults, verifies database migration forward-compatibility, and guarantees automated rollback in under 60 seconds.\n\n## 1. Platform Configuration Archetypes\n\n### A. Vercel (`vercel.json`)\nUsed for Next.js, SvelteKit, and frontend\u002Fserverless architectures:\n```json\n{\n  \"buildCommand\": \"npm run build\",\n  \"outputDirectory\": \".next\",\n  \"framework\": \"nextjs\",\n  \"regions\": [\"iad1\"],\n  \"cleanUrls\": true,\n  \"headers\": [\n    {\n      \"source\": \"\u002F(.*)\",\n      \"headers\": [\n        { \"key\": \"X-Content-Type-Options\", \"value\": \"nosniff\" },\n        { \"key\": \"X-Frame-Options\", \"value\": \"DENY\" }\n      ]\n    }\n  ]\n}\n```\n- **CLI Commands**: `vercel deploy` (preview), `vercel deploy --prod` (production promote).\n- **Environment Scope**: Segregate variables between Development, Preview, and Production.\n\n### B. Netlify (`netlify.toml`)\nUsed for static sites, Jamstack, and Netlify Edge functions:\n```toml\n[build]\n  command = \"npm run build\"\n  publish = \"dist\"\n\n[[redirects]]\n  from = \"\u002F*\"\n  to = \"\u002Findex.html\"\n  status = 200\n\n[[headers]]\n  for = \"\u002F*\"\n  [headers.values]\n    Strict-Transport-Security = \"max-age=31536000; includeSubDomains; preload\"\n```\n- **CLI Commands**: `netlify deploy`, `netlify deploy --prod`.\n\n### C. Fly.io (`fly.toml`)\nUsed for full-stack Node.js, Go, Python, and containerized long-running services:\n```toml\napp = \"production-app\"\nprimary_region = \"iad\"\n\n[build]\n  dockerfile = \"Dockerfile\"\n\n[http_service]\n  internal_port = 3000\n  force_https = true\n  auto_stop_machines = \"stop\"\n  auto_start_machines = true\n  min_machines_running = 1\n\n[[http_service.checks]]\n  grace_period = \"10s\"\n  interval = \"15s\"\n  method = \"GET\"\n  timeout = \"5s\"\n  path = \"\u002Fhealthz\"\n```\n- **CLI Commands**: `fly launch`, `fly secrets set KEY=VALUE`, `fly deploy`, `fly releases rollback`.\n\n### D. Railway (`railway.json` \u002F Nixpacks)\nUsed for microservices, Redis, PostgreSQL, and background worker queues:\n```json\n{\n  \"$schema\": \"https:\u002F\u002Frailway.com\u002Frailway.schema.json\",\n  \"build\": {\n    \"builder\": \"NIXPACKS\",\n    \"buildCommand\": \"npm run build\"\n  },\n  \"deploy\": {\n    \"startCommand\": \"node dist\u002Findex.js\",\n    \"healthcheckPath\": \"\u002Fhealthz\",\n    \"healthcheckTimeout\": 100,\n    \"restartPolicyType\": \"ON_FAILURE\",\n    \"restartPolicyMaxRetries\": 10\n  }\n}\n```\n- **CLI Commands**: `railway up`, `railway variables set KEY=VALUE`.\n\n### E. Cloudflare Pages & Workers (`wrangler.toml`)\nUsed for edge compute, global APIs, and static assets with serverless bindings:\n```toml\nname = \"edge-api\"\nmain = \"src\u002Findex.ts\"\ncompatibility_date = \"2026-01-01\"\n\n[vars]\nENVIRONMENT = \"production\"\n\n[[kv_namespaces]]\nbinding = \"CACHE\"\nid = \"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\"\n```\n- **CLI Commands**: `wrangler secret put KEY`, `wrangler deploy`.\n\n### F. AWS (App Runner \u002F ECS Fargate \u002F CDK)\nUsed for enterprise multi-tenant architectures and private VPC deployments:\n- Inject secrets via AWS Secrets Manager or SSM Parameter Store using IAM task roles (`arn:aws:iam::...`). Never bake `.env` into container layers.\n- App Runner: define `apprunner.yaml` with build and run stages, health checks, and auto-scaling rules (min 1, max 10 instances).\n- ECS Fargate: configure Blue\u002FGreen deployments using AWS CodeDeploy with automatic rollback triggered on CloudWatch 5xx alarm breaches.\n\n## 2. Zero-Downtime Migration & Rollback Discipline\n- **Expand\u002FContract Database Pattern**:\n  1. *Phase 1 (Expand)*: Add nullable column or new table. Deploy migration.\n  2. *Phase 2 (Dual Write)*: Deploy application code writing to both old and new schemas.\n  3. *Phase 3 (Backfill)*: Asynchronously backfill historical data.\n  4. *Phase 4 (Contract)*: Deploy code reading exclusively from new schema; drop old column in a subsequent release.\n- **Rollback Runbook**:\n  - Keep previous deployment artifact\u002Fimage digest tagged (`:v3.0.0-previous`).\n  - Automated platform rollback: `fly releases rollback`, `vercel rollback [deployment-url]`, or AWS ECS task definition reversion.\n\n## Critical Rules\n1. Never run destructive database migrations (`DROP COLUMN`, `ALTER TABLE ... RENAME`) in the same deployment as application code changes.\n2. Production builds must run from committed git SHAs, never uncommitted local dirty states.\n3. Every production service must expose an unauthenticated, lightweight `\u002Fhealthz` endpoint verifying process vitality and database connectivity.\n\n## Verification Checklist\n- [ ] Target platform configuration file (`vercel.json`, `fly.toml`, `netlify.toml`, `railway.json`, `wrangler.toml`) committed and validated.\n- [ ] Environment secrets populated in platform vault; no secrets committed to git or exposed in client bundles.\n- [ ] Health check endpoint (`\u002Fhealthz`) verified returning HTTP 200 before cutover.\n- [ ] Database migrations tested in staging for forward-compatibility.\n- [ ] Instant rollback mechanism (CLI command or container rollback) verified and tested.\n\n## Anti-Patterns\n- NEVER run database migrations inside the container startup script (`CMD`); execute migrations as a separate pre-deploy step or release phase.\n- NEVER deploy to production with `latest` Docker tags; pin immutable content digests (`sha256:...`).\n- NEVER store production encryption keys or credentials in repository `.env.production` files.\n",{"name":5,"group":24,"description":7,"last_reviewed":25},"Ship and run",1788652800000,"main","f6a053c46d4bf0f779ea766c929b6f6f92c51765","skills\u002Fdeployment","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskillary","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp","poorvithmp.com","Shipping tools for problems people notice too late.","2026-10-02 21:32:22",{"source":8,"skillName":5,"commands":36,"prompt":46,"zipAvailable":47},[37,40,43],{"tool":38,"command":39},"npx","npx skills add poorvith-mp\u002Fskills-developer --skill deployment",{"tool":41,"command":42},"bunx","bunx skills add poorvith-mp\u002Fskills-developer --skill deployment",{"tool":44,"command":45},"pnpm","pnpm dlx skills add poorvith-mp\u002Fskills-developer --skill deployment","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Fdeployment\u002FSKILL.md",true,[49,55],{"path":50,"resourceType":51,"resourceTypeDesc":52,"sizeBytes":53,"sourceHtmlUrl":54},"deployment.skill","OTHER","其他",3440,"https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Fdeployment\u002Fdeployment.skill",{"path":56,"resourceType":57,"resourceTypeDesc":58,"sizeBytes":59,"sourceHtmlUrl":60},"evals\u002Frouting.yaml","REFERENCE","参考文档",909,"https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Fdeployment\u002Fevals\u002Frouting.yaml",[62,69,76,83,90,97],{"skillNo":63,"name":64,"nameZh":6,"description":65,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":66,"categories":67,"keywords":68,"publishedAt":19},"01M792Q79X14YD94WXEEJY9GCW","workflow-optimizer","Moved to workflow-mapping in skills-agents. Removed in v4.1.","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Fworkflow-optimizer\u002FSKILL.md",[],[],{"skillNo":70,"name":71,"nameZh":6,"description":72,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":73,"categories":74,"keywords":75,"publishedAt":19},"01M792Q387DNC91VKEVM07SJM3","webhooks","Build webhook receivers with signature verification, idempotency, retries and dead letter queues. Use when implementing, verifying, or signing incoming\u002Foutgoing webhooks.","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Fwebhooks\u002FSKILL.md",[],[],{"skillNo":77,"name":78,"nameZh":6,"description":79,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":80,"categories":81,"keywords":82,"publishedAt":19},"01M792PZW0SM71X7V9709ZWHCR","webhook-handler-builder","Moved to webhooks in skills-developer. Removed in v4.1.","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Fwebhook-handler-builder\u002FSKILL.md",[],[],{"skillNo":84,"name":85,"nameZh":6,"description":86,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":87,"categories":88,"keywords":89,"publishedAt":19},"01M792PW7XPB7J9S0QSS52JXZV","voice-ai-integration-engineer","Moved to speech-pipelines in skills-developer. Removed in v4.1.","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Fvoice-ai-integration-engineer\u002FSKILL.md",[],[],{"skillNo":91,"name":92,"nameZh":6,"description":93,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":94,"categories":95,"keywords":96,"publishedAt":19},"01M792PRZ5GSAQ1P2999V9XAJ5","typescript-migrator","Moved to port-code in skills-developer. Removed in v4.1.","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Ftypescript-migrator\u002FSKILL.md",[],[],{"skillNo":98,"name":99,"nameZh":6,"description":100,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":101,"categories":102,"keywords":103,"publishedAt":19},"01M792PQDARKP00V8Z3GYD4QZP","trigger-dev","Moved to trigger-dev in skills-agents. Removed in v4.1.","https:\u002F\u002Fgithub.com\u002Fpoorvith-mp\u002Fskills-developer\u002Fblob\u002Fmain\u002Fskills\u002Ftrigger-dev\u002FSKILL.md",[],[]]