Phase 12 · Deploy to production
The final gate: take the staging-verified app live without losing anything if it goes wrong. Phase 12 is not a sequential step you grind through — it’s a trigger you pull when staging is verified and you’re ready. Every move here keeps a rollback one command away.
Phase 12 — production cutover, rollback always ready
When to pull the trigger
Section titled “When to pull the trigger”Phase 12 can fire on three paths depending on your risk tolerance. Pick one — don’t drift between them.
| Path | When to use | Flow |
|---|---|---|
| Fast launch | Need production ASAP | Core phases on the selected non-production target → go live → harden + polish there → redeploy |
| Hardened launch | Want everything right first | All phases on the selected non-production target → go live → final verification |
| Iterative | Prefer gradual refinement | Core phases → go live → polish on the selected non-production target, redeploy after each batch |
Prerequisites
Section titled “Prerequisites”Confirm every item before any deploy step runs:
- Entry gate (Task P.0) — Phase 12 production is blocked unless the Phase 10-CONSOLIDATED verdict (
Admin-Local/1-Project/4-Audit-Reports/...-phase-10-CONSOLIDATED.md) is 🟢 GO or an explicitly accepted 🟡 CONDITIONAL GO. 🔴 NO-GO = hard block, no exceptions. A missing verdict = STOP — deploy nothing. - Production environment row exists in
Zaj-PROJECT.md— URL/domain, hosting account, SSH alias, host/user/port, deploy target, source branch, DB name, web PHP, CLI PHP binary, credential pointer, noindex/robots posture, and last verified date are filled and current. - Staging deploy immediate gate complete — app live on the selected non-production target, schema verified, rollback proven, agent-drivable monitor/auth sweeps clean, and any passive 24–48h watch or human-only journeys tracked. For production cutover, the passive watch must be completed or explicitly accepted in the launch decision.
- Superadmin setup done on the selected non-production target — branding, SMTP, payments, and legal pages all configured.
- Server setup verified on the production account (it may be a different host from staging — server setup runs on each).
- Production database created (empty) in the hosting panel.
- Production
.envtemplate prepared in your secrets manager / project vault — placeholders only, never committed. - Production DNS + TLS ready — the production
Arecord resolves to the current origin IP fromZaj-PROJECT.md, the origin cert / Let’s Encrypt cert is issued, and any Cloudflare proxy is Full (Strict). A public Cloudflare525is a hard block, not an app-deploy state. - Rollback plan reviewed, emergency contacts documented, and stakeholders notified of the deploy window.
Database strategy — decide first
Section titled “Database strategy — decide first”How you seed the production database decides how much work you repeat.
| Option | Pros | Cons |
|---|---|---|
| Fresh installer | Clean DB, no URL/encryption issues | Redo all superadmin config (1–2h) |
| Copy verified non-production DB | Skip admin config (~10 min) | Must find/replace non-production→production URLs; watch app-key-encrypted columns |
| Hybrid | Best of both | Fresh install, then selectively import settings/plans; needs SQL comfort |
For a first production deploy, Fresh installer is safest — it avoids encryption-key mismatches and URL find/replace errors. Copy a verified non-production DB only once the process is routine and the source environment row is current in Zaj-PROJECT.md.
Pages in this phase
Section titled “Pages in this phase” Two ways to run this:
Whole Phase → click the button; one Part → open the Part document and click Run this Part.
Skill users can run /zaj-laravel-codecanyon phase 12 instead.
Start with Pre-flight — never skip it.