diff --git a/CLAUDE.md b/CLAUDE.md index 87597a5..61c58a5 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -18,6 +18,19 @@ Replaces WhatsApp/Excel safety reporting. Client: Ms. Agnes, Mr. Terence, Mr. Ya **All phases (0–6) complete as of 2026-07-12.** Remaining work is ops: production env vars (`SUPABASE_SERVICE_ROLE_KEY`, Meta WhatsApp, Resend, `CRON_SECRET`), VPS cron registration (`docs/vps-cron.md`), optional Supabase Pro for image thumbnails. See `[[phases]]` memory for full phase breakdown and deliverables. +## Deployment (Production) + +**CRITICAL — Deploy path is `/opt/wsims/app` on 175.136.239.121:9321, NOT `/var/www/ims`.** + +```bash +# Correct deployment: +tar -czf - package.json package-lock.json .next | \ + ssh -p 9321 setia@175.136.239.121 "cd /opt/wsims/app && tar -xzf -" +pm2 restart wsims +``` + +PM2 process `wsims` runs from `/opt/wsims/app`. Nginx proxies `ims.setia.com.my` → `http://127.0.0.1:3003`. + ## Dev Conventions - Never commit `.env` or API keys. All secrets in env vars only. - RLS enforced at DB level for every table — never rely on UI-only hiding.