This is a lightweight notification service using Express, TypeORM, Redis, and BullMQ to handle real-time and persistent notifications for your application.
git clone https://github.com/<your-username>/notification-service.gitcd notification-service 2. Install Dependencies
npm install
- Environment Configuration Create a .env file in the root directory:
env
PORT=4500
REDIS_HOST=localhost
REDIS_PORT=6379
DB_HOST=localhost
DB_PORT=5432
DB_USERNAME=postgres
DB_PASSWORD=yourpassword
DB_NAME=notification_service
redis_url=localhost
-
Start PostgreSQL and Redis Ensure PostgreSQL and Redis are up and running on the configured ports.
-
Run Migrations
npx typeorm-ts-node-commonjs migration:run -d ./src/data-source.ts
This will run the migrations and create the required tables in the PostgreSQL database.
🚀 Running the Server
npm start