Home - agoenks29D/exzly GitHub Wiki
Exzly is a modular, scalable, and developer-friendly base project built with Node.js and Express.js.
It is designed as a reusable boilerplate to help developers quickly build production-ready web applications by providing essential features such as:
- ๐งโ๐ผ Built-in User Management
- ๐ Modular Architecture with Git-based Feature Branching
- โ๏ธ Easy Feature Integration (just merge the branches you need!)
Instead of reinventing the wheel for every project, developers can simply clone Exzly, pick the features they want from the available branches, and start building right away.
๐ฑ Project Vision
"One codebase, many possibilities."
Exzly aims to simplify the repetitive setup phase of backend development by offering a strong, extensible starting point.
๐ณ Core Features
- โ Built-in User Management (Authentication, Roles, Permissions)
- ๐ Environment-based Configuration System
- ๐ ๏ธ Pre-configured Linting and Testing (ESLint, Prettier, Jest)
- ๐ Secure by Default (Helmet, CORS enabled)
- ๐ฆ Sequelize ORM for database operations
- ๐งช Jest & Supertest for writing API tests
๐ฟ Feature Branches
Below is a list of feature branches available in this repository (subject to update as the project evolves):
Branch Name | Brief Description |
---|---|
feature/blog |
Blogging and article module |
feature/product |
Product and catalog module |
feature/oauth |
OAuth integration (e.g., Google, Facebook) |
feature/service-worker |
Custom Service Worker setup for PWA capabilities |
feature/push-notification |
Push Notification support (Web Push) |
feature/object-storage |
Integration with object storage (e.g., S3, MinIO) |
...and more... | More features planned or in progress |
๐ Project Structure
โ ๏ธ Note: Some feature branches may introduce structural changes or add new directories to support their respective features. However, the base project (i.e., the main branch) follows the standardized structure shown below:
- database/ # Database-related files
โโ migrations/ # Sequelize migration files
โโ seeders/ # Sequelize seeder files
- public/ # Static assets (images, CSS, JS for frontend)
- src/ # Main source code
โโ config/ # App configuration (security, module, etc.)
โโ helpers/ # Helper functions and utilities
โโ middlewares/ # Express middleware (auth, error handling, etc.)
โโ models/ # Sequelize models
โโ routes/ # Route definitions
โ โโ admin/ # Routes for admin panel
โ โโ api/ # RESTful API routes
โ โโ web/ # Web (frontend) routes
โโ utils/ # Utility modules (e.g., logger, debugger, JWT)
โโ validators/ # Request validation using express-validator
โโ views/ # Nunjucks templates
โโ admin/ # Nunjucks templates for admin views
โโ email/ # Templates for email
โโ web/ # Public site templates
โ๏ธ Project Environment
โ ๏ธ Note: Environment variables may vary across branches depending on the feature requirements (e.g., integrations with third-party services like Firebase, Web Push, or payment gateways). Below is the base environment configuration used in the main branch:
Variable | Description | Example Value | Actions secrets and variables |
---|---|---|---|
TZ |
Time zone setting | UTC |
variable |
PORT |
Port number for the application to listen on | 3000 |
secret |
DEBUG |
Environment variable for debugging and logging | express.* |
variable |
APP_NAME |
Name of the application | Exzly |
variable |
NODE_ENV |
The environment the app is running in (e.g., development, production) | development |
variable |
TRUST_PROXY |
Trust proxy setting (1 enables trust) | 1 |
secret |
STORAGE_PATH |
Path to storage folder | storage |
secret |
SESSION_SECRET |
Secret key used for session management | Exzly |
secret |
SESSION_EXPIRATION |
Session expiration time | 4h |
secret |
ASSETS_URL |
Base URL for serving static assets (useful when using CDN to avoid hardcoding paths) | / |
variable |
HTTPS | |||
ENABLE_HTTPS |
Enable or disable HTTPS | true |
variable |
SSL_KEY_FILE |
Path to the SSL key file for HTTPS | PATH/TO/SSL_KEY_FILE.key |
secret |
SSL_CERT_FILE |
Path to the SSL certificate file | PATH/TO/SSL_CERT_FILE.crt |
secret |
Database | |||
DB_SYNC |
Enable or disable database sync | true |
variable |
DB_MODE |
Mode for database synchronization: alter (non-destructive changes), force (drops and recreates all tables) | alter |
variable |
DATABASE_NAME |
Name of the database | exzly_development |
secret |
DATABASE_USER |
Username used to connect to the database | root |
secret |
DATABASE_PASS |
Password for the database user | (leave blank if not needed) | secret |
DATABASE_HOST |
Host address of the database server | localhost |
secret |
DATABASE_TIME |
Timezone offset for the database connection | +00:00 |
secret |
DATABASE_DIALECT |
Type of SQL dialect used (e.g., mysql, postgres) | mysql |
secret |
DATABASE_CONFIG |
Configuration file for advanced DB settings | config.js or config.json |
secret |
Security: JWT | |||
JWT_SECRET |
Secret key for JWT authentication | Exzly |
secret |
JWT_EXPIRATION |
JWT expiration time | 4h |
secret |
SMTP | |||
SMTP_PORT |
SMTP port | 587 |
secret |
SMTP_HOST |
SMTP server host | sandbox.smtp.mailtrap.io |
secret |
SMTP_FROM |
From email address used in SMTP | No Reply <[email protected]> |
secret |
SMTP_USER |
SMTP username | db71a9eabfxxxx |
secret |
SMTP_PASS |
SMTP password | 74606e0fa9xxxx |
secret |
Routes | |||
WEB_ROUTE |
Base route for web pages | / |
secret |
API_ROUTE |
Base route for API endpoints | /api |
secret |
ADMIN_ROUTE |
Base route for admin panel | /admin |
secret |