# LeadPilot — Production Hardening Guide

**Document Version:** 1.0.0 (Phase 23)

---

## 1. Environment & Web Server Configuration

1. **Set `APP_ENV=production` & `APP_DEBUG=false`** in `.env`.
2. **Force HTTPS & TLS 1.3:** Configure Nginx/Apache with HSTS and SSL certificates.
3. **Configure Permissions:** Web server user writeable only on `storage/` and `bootstrap/cache/`.
4. **Security Headers Middleware:** Active with `nosniff`, `SAMEORIGIN`, `strict-origin-when-cross-origin`, and `Content-Security-Policy`.
5. **Worker Execution:** Execute queue and follow-up cron workers via CLI daemon rather than web hooks.
