Overview
Voxora provides npm scripts for development, building, testing, and deployment. All scripts can be run from the root directory.Development Scripts
dev
Start all development servers (requires Docker to be started separately):- Starts Next.js web app on port 3000
- Starts Express API server on port 3002
- Enables hot reload for both apps
- Uses Turborepo for parallel execution
dev:full
Start Docker services and all development servers:- Starts Docker services (MongoDB, Redis, etc.)
- Starts all development servers
- One command for complete setup
dev (workspace-specific)
Start individual workspace in development mode:Docker Scripts
docker:start
Start all Docker services in detached mode:- MongoDB on port 27017
- Redis on port 6379
- Mongo Express on port 8081
- MailHog on ports 1025 (SMTP) and 8025 (UI)
docker:stop
Stop and remove all Docker containers:docker:clean
Stop containers and remove all volumes (data loss):docker:logs
View logs from Docker services:Build Scripts
build
Build all applications for production:- Builds Next.js app (creates
.nextdirectory) - Transpiles API code (if using TypeScript)
- Generates optimized production bundles
build (workspace-specific)
Build individual workspace:Testing Scripts
test
Run all tests across workspaces:test:watch
Run tests in watch mode:test:coverage
Generate test coverage report:- Coverage report in
coverage/directory - HTML report at
coverage/lcov-report/index.html
test (workspace-specific)
Code Quality Scripts
lint
Run ESLint on all workspaces:- JavaScript/TypeScript syntax errors
- Code style violations
- Best practice violations
lint:fix
Automatically fix linting issues:format
Format code with Prettier:- JavaScript/TypeScript files
- JSON files
- Markdown files
- CSS files
format:check
Check if files are formatted correctly:Dependency Management
install
Install all dependencies:update
Update dependencies to latest versions:outdated
Check for outdated dependencies:audit
Check for security vulnerabilities:Cleanup Scripts
clean
Remove build artifacts and dependencies:node_modulesdirectories.nextdirectorydistdirectories- Build caches
clean:full
Complete cleanup including Docker volumes:Database Scripts
db:seed
Seed database with sample data:db:reset
Reset database to initial state:db:migrate
Run database migrations:Production Scripts
start
Start production servers:Must run
npm run build before npm run startUtility Scripts
type-check
Run TypeScript type checking:validate
Run all validation checks:- Type checking
- Linting
- Tests
- Format check
Custom Makefile Commands
TheMakefile provides additional convenience commands:
Setup
npm installnpm run docker:start- Copy environment files
Dev
npm run dev:full
Reset
- Stop Docker
- Clean all files
- Reinstall dependencies
- Restart services
Turborepo Scripts
Voxora uses Turborepo for efficient monorepo management.Run with filtering
Clear Turbo cache
Git Hooks
Pre-commit hooks run automatically:Pre-commit
Runs ongit commit:
- Lint staged files
- Format staged files
- Run type check
Pre-push
Runs ongit push:
- Run all tests
- Check for build errors
CI/CD Scripts
Scripts used in GitHub Actions:ci
Run CI validation:- Install dependencies
- Type check
- Lint
- Test
- Build
deploy
Deploy to production:Environment-Specific Scripts
dev:https
Run development server with HTTPS:debug
Start in debug mode:Script Chaining
Run multiple scripts in sequence:Workspace-Specific Scripts
Each workspace may have additional scripts. Checkpackage.json in:
apps/web/package.jsonapps/api/package.jsonpackages/*/package.json
Quick Reference Table
| Script | Description | When to Use |
|---|---|---|
npm run dev | Start dev servers | Daily development |
npm run dev:full | Start Docker + dev servers | First time setup |
npm run build | Build for production | Before deployment |
npm run test | Run tests | Before committing |
npm run lint | Check code quality | Before committing |
npm run format | Format code | After writing code |
npm run docker:start | Start services | When services stopped |
npm run docker:stop | Stop services | End of day |
npm run clean | Clean builds | Troubleshooting |
Next Steps
Development Setup
Complete development guide
Docker Services
Managing Docker services
Contributing
How to contribute
Deployment
Deploy to production