- Node.js
- Express.js
- MongoDB
- Docker
- Nginx
- Kubernetes
- Stripe
- User Service: Handles user registration & authentication.
- Product Service: Manages product listings, categories, and inventory.
- Shopping Cart Service: Manages users’ shopping carts, including adding/removing items and updating quantities.
- Order Service: Processes orders, including placing orders, tracking order status, and managing order history.
- Payment Service: Handles payment processing, integrating with
Stripepayment gateway. - Notification Service: Sends email and SMS notifications using
NodeMailerandTwilio.
- Microservices Architecture: Each service is a separate codebase, with its own database.
- API Gateway & Load Balancing:
Nginxis used as an API gateway to route requests to the appropriate service and as a Load Balancer to distribute the load across multiple instances of the same service. - Containerization:
Dockeris used to containerize each service, making it easy to deploy and scale the services. - Deployment:
Kubernetesis used to deploy and manage the services in a production environment, providing scalability, fault tolerance, and self-healing capabilities. - CI/CD Pipeline:
Github Actionsis used for CI/CD to automate the deployment process, including building, testing, and deploying the services. - Database:
MongoDBis used as the database for all services, providing a flexible schema and scalability.Mongooseis used as the ODM to interact with MongoDB. - Authentication & Authorization:
JWTis used for authentication andargon2is used for password hashing.
-
Docker & Docker Compose should be installed.
docker --version docker compose version
-
Create and update all
.envfiles with the required values for each service.
docker compose up --buildHere --build is used to build the image again if there are any changes in the code.
- Add
DOCKER_USERNAME&DOCKER_PASSWORDto github secrets to push the image to docker hub.