Live on (https://devcart.onrender.com/)
## FeatureseCommerce platform built with the MERN stack & Redux.
- User Authentication: Secure user authentication for personalized shopping experiences.
- Product Search: Efficient product search functionality for a smoother user experience.
- Cart Management: Seamless cart management for a convenient shopping journey.
- Admin product management, user management, and Admin Order details page.
- Checkout process (shipping, payment method, etc)
- Scalability: Built with Docker and Kubernetes to scale effortlessly in a production environment.
- Database seeder (products & users)
The project incorporates a robust CI/CD pipeline with Jenkins, SonarQube, and Trivy for efficient code analysis, quality assurance, and security scans.
A powerful CI/CD pipeline for DevCart, a MERN e-commerce app, designed for scalability.
-
Clean Workspace: Ensure a fresh start for each build.
-
Checkout from Git: Fetch the latest code from the 'docker' branch.
-
SonarQube Analysis: Perform code analysis for quality assurance.
-
Quality Gate: Ensure code quality meets defined standards.
-
Install Frontend/Backend Dependencies: Set up project dependencies.
-
OWASP & TRIVY Scans: Check for security vulnerabilities in dependencies.
-
Create .env File: Configure environment variables.
-
Docker Build & Push: Build Docker images, tag, and push to the registry.
-
TRIVY Image Scans: Scan Docker images for vulnerabilities.
-
Deploy to Containers: Deploy the application using Docker Compose.
Clone the repository, follow the pipeline steps, and launch DevCart effortlessly.
Feel free to contribute and enhance the pipeline for continuous improvement.
Check out the detailed walkthrough of DevCart on YouTube:
Follow these steps to get the project up and running on your local machine:
git clone https://github.com/Ratnesh4193/devcart.git
cd devcart
cd frontend && npm install
cd ../backend && npm install
touch .env
# Run frontend (:3000) & backend (:5000)
npm run dev
# Run backend only
npm run server
# Create frontend prod build
cd frontend
npm run build
docker-compose up -d --build
Access the application at http://localhost:3000.
There is a Heroku postbuild script, so if you push to Heroku, no need to build manually for deployment to Heroku
You can use the following commands to seed the database with some sample users and products as well as destroy all data
# Import data
npm run data:import
# Destroy data
npm run data:destroy
Sample User Logins
[email protected] (Customer)
123456
[email protected] (Customer)
123456
Contributions are welcome! Fork the repository, create a branch, commit your changes, and open a pull request. Check out the Contributing Guidelines for more details.