Files
Aseret_Bank/QUICKSTART.md
2026-02-09 21:51:31 -08:00

135 lines
2.3 KiB
Markdown

# Quick Start Guide
Get up and running with Aseret Bank Platform in 5 minutes.
## Prerequisites Check
```bash
# Check Node.js (need 18+)
node --version
# Check pnpm (need 8+)
pnpm --version
# Check Docker (optional but recommended)
docker --version
docker-compose --version
```
## Installation
### 1. Install Dependencies
```bash
pnpm install
```
### 2. Setup Environment
```bash
cp .env.example .env
# Edit .env with your settings (or use defaults for local dev)
```
### 3. Start Services
**Option A: Using Docker (Easiest)**
```bash
# Start PostgreSQL and Redis
docker-compose up -d
# Wait a few seconds for services to start
sleep 5
```
**Option B: Local Services**
Make sure PostgreSQL and Redis are running locally.
### 4. Setup Database
```bash
# Generate Prisma client
pnpm db:generate
# Run migrations
pnpm db:migrate
# Seed with sample data
pnpm db:seed
```
### 5. Start Development
```bash
# Start both backend and frontend
pnpm dev
```
Or separately:
```bash
# Terminal 1: Backend
pnpm dev:backend
# Terminal 2: Frontend
pnpm dev:frontend
```
## Access the Application
- **Frontend**: http://localhost:3000
- **Backend API**: http://localhost:3001
- **API Documentation**: http://localhost:3001/api-docs
- **Health Check**: http://localhost:3001/health
- **Prisma Studio**: Run `pnpm db:studio` then visit http://localhost:5555
## Default Credentials
After seeding:
- **Admin**: `admin@aseret.com` / `admin123`
- **Loan Officer**: `officer@aseret.com` / `officer123`
- **Customer**: `customer@example.com` / `customer123`
## Troubleshooting
### Port Already in Use
```bash
# Find what's using the port
lsof -i :3001
# Kill the process or change PORT in .env
```
### Database Connection Error
1. Verify PostgreSQL is running
2. Check DATABASE_URL in `.env`
3. Test connection: `psql $DATABASE_URL`
### Prisma Client Errors
```bash
pnpm db:generate
```
### Module Not Found
```bash
pnpm install
```
## Next Steps
- Read [SETUP.md](./SETUP.md) for detailed setup instructions
- Check [README.md](./README.md) for project overview
- Review [CONTRIBUTING.md](./CONTRIBUTING.md) for development guidelines
## Need Help?
- Check the logs: `pnpm docker:logs` (if using Docker)
- Review error messages in terminal
- Check database connection: `pnpm db:studio`