Technical Architecture
Technology stack, infrastructure, hosting, and security
🏗️ System Architecture
💻 Technology Stack
| What | Technology | Why We Chose It |
|---|---|---|
| Website | React 18 | Industry standard, fast, huge community |
| Mobile App | React Native (Expo) | One codebase for iOS & Android |
| Backend API | Node.js + Express | Fast, handles many requests, JavaScript everywhere |
| Database | PostgreSQL 16 | Most reliable open-source DB, enterprise-grade |
| Cache | Redis 7 | Lightning-fast for sessions and frequent data |
| Search | Meilisearch | Typo-tolerant instant search |
| Payments | Stripe | World's most trusted payment processor |
| BNPL | Tabby + Tamara | UAE's most popular buy-now-pay-later |
| SendGrid | Reliable delivery for order notifications | |
| SMS | Twilio | OTP and notification SMS |
| CDN | Cloudflare | Fast global delivery, DDoS protection |
| Deployment | PM2 + GitHub Actions | Automated, zero-downtime deploys |
🖥️ Your Dedicated Server (VPS)
You will have your own dedicated Virtual Private Server — not shared with anyone.
| Component | Spec | What It Means |
|---|---|---|
| Location | UAE/Bahrain Region | <50ms latency for UAE visitors |
| OS | Ubuntu 22.04 LTS | Enterprise-grade, updates until 2027 |
| Backups | Daily automated | 30-day retention, instant restore |
| SSL | Let's Encrypt | Free HTTPS, auto-renewing |
| Uptime | 99.9% SLA | Less than 9 hours downtime per year |
🔐 Security Architecture
Cloudflare WAF
Blocks DDoS attacks, bots, and known attack patterns before they reach your server
Nginx Rate Limiting
Prevents brute force attacks, throttles excessive requests
JWT Authentication
Token-based auth with session management and role verification
Application Security
Input validation, CORS, CSRF/XSS protection, SQL injection prevention
Data Encryption
AES-256 encryption at rest, TLS 1.3 in transit
Monitoring & Alerts
Real-time threat detection, audit logging, automated alerts
Compliance
| Standard | Status | Description |
|---|---|---|
| UAE Data Protection | ✓ Compliant | UAE Personal Data Protection Law |
| PCI DSS | ✓ Via Stripe | No card data touches your server |
| OWASP Top 10 | ✓ Protected | All web vulnerabilities addressed |
| 2FA for Admins | ✓ Required | All staff must use 2-factor auth |
| GDPR-Ready | ✓ Ready | Data export and deletion capabilities |
🚀 Deployment Pipeline
Code Push
Developer pushes code to GitHub repository
Automated Tests
GitHub Actions runs all unit and integration tests
Build
Production assets built (React web + API)
Deploy
Zero-downtime deployment to VPS via PM2
Health Check
Automated verification that everything is running correctly
💡 Zero downtime
Your customers will never see a maintenance page. Updates happen instantly without any interruption.
📈 Scalability Path
| Stage | Users | Infrastructure |
|---|---|---|
| Launch | 0 – 10K | Single VPS (current setup) |
| Growth | 10K – 50K | Add DB read replica, increase specs |
| Scale | 50K – 200K | Multiple API servers + load balancer |
| Enterprise | 200K+ | Container orchestration (Kubernetes) |