# PHASE 15: DEPLOYMENT AND LAUNCH

Read `docs/09-LAUNCH-RUNBOOK.md` and follow it exactly, in order. This prompt does not restate it, the runbook is the document of record.

## Preconditions, all must be true before you start

- [ ] Phase 14 signed off, the full QA plan passed
- [ ] A restore has actually been tested, with the time recorded
- [ ] The brand name is set and `RENAME.md` was executed. **Ideally this happened around phase 01**, as `RENAME.md` itself advises. If it is only happening now, run the data migration in `RENAME.md` section 6 as well, and expect a slower, riskier rename.
- [ ] The domain is known and open questions 1 to 8 are answered
- [ ] TTL on existing DNS records lowered to 300 seconds, at least 24 hours ago
- [ ] Product photography and copy are in place for the launch catalogue

If any of these is false, stop and say which one.

## Scope

1. Set up the staging subdomain properly if it does not already exist: own database, `WP_ENVIRONMENT_TYPE = 'staging'`, forced `noindex`, cPanel password protection, emails intercepted.
2. Set up cPanel Git Version Control with `deploy/.cpanel.yml`, deploying only the theme and plugin directories. If Git Version Control is not available on the plan, script an SFTP push of those two directories only and document it.
3. Execute the launch runbook, steps 1 through 14, in order. Do not reorder. Do not skip step 6, search engine visibility, it is the one that gets forgotten.
4. Run the twenty-minute post-launch smoke test on mobile data, not wifi, including placing and then cancelling a real COD order.
5. Record the PageSpeed baseline.
6. Watch for 72 hours per runbook step 14.

## Handover deliverables

7. `docs/HANDOVER.md` covering: how to add a product, how to run the daily verification routine, how to assign a courier and tracking, how to record COD collection, how to create a settlement, how to read the dashboard, what not to install and why, who to call when something breaks.
8. A one-page daily operating checklist the owner can print.
9. Credentials handed over through a password manager, never over WhatsApp or email.
10. `docs/PROGRESS.md` finalised with the launch baseline numbers and any deviations from spec accumulated across all phases.

## Acceptance criteria

- [ ] Every item on the condensed launch checklist at the end of the runbook is ticked
- [ ] A real COD order placed on the live site reached admin, sent both emails to the inbox, and fired one purchase event in GA4 and one in Meta with server deduplication
- [ ] `robots.txt` does not disallow everything, and no `noindex` header is being sent
- [ ] Ten product URLs, five category URLs, cart, checkout, my-account and track-order all resolve
- [ ] Order emails land in the inbox in Gmail, Outlook and a Pakistani ISP address
- [ ] SPF, DKIM and DMARC records all present and validating
- [ ] Backups running against the live site, and one restore tested from the live backup
- [ ] PageSpeed baseline recorded for homepage and one product page
- [ ] Handover doc written and the owner has been walked through it

## After launch

The agreed hosting trigger from decision D-22 stands: **at 40 orders per day, or the first 508 error under ad traffic, move to a VPS with Redis.** Do not wait to discover this during a campaign.

First post-MVP items, in priority order: a courier API integration (TCS, Leopards or PostEx), then a payment gateway once merchant onboarding completes, then customer accounts if the order-lookup page proves insufficient.
