Skip to content

Commit b050619

Browse files
committed
feat: add Readme
1 parent e7008c1 commit b050619

File tree

1 file changed

+110
-0
lines changed

1 file changed

+110
-0
lines changed

README.md

Lines changed: 110 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
# DevTrack Pro
2+
3+
> A high-performance SaaS platform for developer productivity, featuring polyglot persistence, robust CI/CD, and a decoupled architecture.
4+
5+
![CI/CD Status](https://img.shields.io/badge/CI%2FCD-GitHub_Actions-2088FF?style=flat-square&logo=github)
6+
![Coverage](https://img.shields.io/badge/Coverage-80%25-brightgreen?style=flat-square)
7+
![Backend](https://img.shields.io/badge/Backend-NestJS-E0234E?style=flat-square&logo=nestjs)
8+
![Frontend](https://img.shields.io/badge/Frontend-React%20%2B%20Vite-61DAFB?style=flat-square&logo=react)
9+
10+
## Overview
11+
12+
DevTrack Pro is a full-stack developer productivity suite designed to handle complex project management and real-time analytics. Built with a modern micro-services mindset, it implements a **Polyglot Persistence** architecture, utilizing PostgreSQL for strong relational data consistency and MongoDB for high-speed metric aggregation.
13+
14+
## Key Features
15+
16+
* **Advanced Authentication:** Secure JWT-based auth with HTTP-only cookies and third-party API integration for reliable password recovery (via Resend HTTP API to bypass standard cloud SMTP restrictions).
17+
* **Polyglot Database Architecture:** * Relational data (Users, Projects, Tasks) managed via **PostgreSQL** + TypeORM.
18+
* Application metrics and logging managed via **MongoDB** + Mongoose for optimized aggregation pipelines.
19+
* **Automated CI/CD Pipeline:** Fully automated testing and deployment workflows using GitHub Actions.
20+
* **Quality Assurance Gate:** Strict 80% minimum test coverage threshold enforced at the pipeline level before any deployment.
21+
22+
## Tech Stack
23+
24+
### Frontend (Deployed on Vercel)
25+
* **Framework:** React 18 + Vite (TypeScript)
26+
* **Styling:** Tailwind CSS
27+
* **Testing:** Vitest + React Testing Library
28+
29+
### Backend (Deployed on Render)
30+
* **Framework:** NestJS (TypeScript)
31+
* **Persistence:** TypeORM & Mongoose
32+
* **Email Service:** Resend (HTTP API)
33+
* **Testing:** Jest (Unit & E2E)
34+
35+
### Infrastructure & Databases
36+
* **PostgreSQL:** Serverless hosting via Neon.
37+
* **MongoDB:** Cloud hosting via MongoDB Atlas.
38+
* **CI/CD:** GitHub Actions (Automated build, test, and deploy triggers).
39+
40+
## Architecture & Deployment
41+
42+
The application follows a decoupled client-server architecture:
43+
1. **GitHub Actions** acts as the gatekeeper. On every push to `main`, it provisions a Node.js runner, installs dependencies, lints, and runs the entire test suite.
44+
2. If tests pass (and maintain >80% coverage), the pipeline signals the cloud providers.
45+
3. **Render** pulls the backend code, injects secure environment variables, connects to the cloud databases via SSL, and exposes the RESTful API.
46+
4. **Vercel** builds the optimized React static assets and deploys them to a global Edge CDN, dynamically routing API calls to the Render backend.
47+
48+
## Local Development Setup
49+
50+
To run this project locally, you will need Node.js (v20+) and Docker Desktop installed. We use Docker Compose to orchestrate the local database infrastructure.
51+
52+
### 1. Clone the repository
53+
```bash
54+
git clone [https://github.com/yourusername/devtrack-pro.git](https://github.com/yourusername/devtrack-pro.git)
55+
cd devtrack-pro
56+
```
57+
58+
### 2. Infrastructure Setup (Docker)
59+
60+
Spin up the local PostgreSQL and MongoDB instances in detached mode:
61+
62+
```bash
63+
docker-compose up -d
64+
```
65+
66+
### 3. Backend Setup
67+
```bash
68+
cd backend
69+
npm install
70+
```
71+
Create a `.env` file in the `backend` directory:
72+
```env
73+
PORT=3000
74+
POSTGRES_HOST=localhost
75+
POSTGRES_PORT=5432
76+
POSTGRES_USER=root
77+
POSTGRES_PASSWORD=rootpassword
78+
POSTGRES_DB=devtrack_db
79+
MONGO_URI=mongodb://root:rootpassword@localhost:27017/devtrack_metrics?authSource=admin
80+
JWT_SECRET=your_super_secret_development_key
81+
RESEND_API_KEY=your_resend_api_key
82+
FRONTEND_URL=http://localhost:5173
83+
```
84+
Run the development server:
85+
```bash
86+
npm run start:dev
87+
```
88+
89+
### 3. Frontend Setup
90+
```bash
91+
cd ../frontend
92+
npm install
93+
```
94+
Create a `.env.local` file in the `frontend` directory:
95+
```env
96+
VITE_API_URL=http://localhost:3000
97+
```
98+
Run the frontend:
99+
```bash
100+
npm run dev
101+
```
102+
103+
## Testing
104+
105+
Testing is a first-class citizen in this project.
106+
* **Backend:** `cd backend && npm run test:cov` (Generates full coverage report)
107+
* **Frontend:** `cd frontend && npm run test` (Runs Vitest UI component tests)
108+
109+
## License
110+
This project is licensed under the MIT License.

0 commit comments

Comments
 (0)