SMB: SPA + Backend API
Solution Components
Architecture Visual
SMB: SPA + Backend API
As businesses grow, separating the frontend and backend becomes crucial for independent scaling and team specialization. This pattern serves a compiled application (SPA) alongside a REST/GraphQL API.
Core Components:
- Frontend: A React, Vue, or Angular application built into static files, served directly by Nginx.
- Backend API: A generic backend (Node, Python, Go) exposing JSON APIs.
- Nginx Gatekeeper: Routes traffic based on path (
/api/*vs/*), manages CORS, and handles SSL. - Database: Managed database instance (RDS, Cloud SQL, etc.) for reliability.
Deployment: Usually deployed via CI/CD pipelines that build artifacts (JS bundles, binaries) and copy them to the VM or update the running process.
Tech Stack
| Component | Technology |
|---|---|
| Segment | smb |
| Deployment | vm-decoupled |
| Frontend | react-vue-angular |
| Backend | node-python-go |
| Web Server | nginx |
| Database | postgres-mysql |
Cloud Cost Estimator
Dynamic Pricing Calculator