This project demonstrates a complete Kubernetes-based CI/CD pipeline for a Node.js web application, focused on improving deployment efficiency, scalability, and reducing manual efforts. The setup includes containerization with Docker, deployment management through Kubernetes, and an automated CI/CD pipeline using Jenkins.
This project containerizes a Node.js web application with Docker, enabling efficient, consistent deployments. It utilizes Kubernetes for managing deployment and scaling, enhancing resource utilization. An integrated Jenkins-based CI/CD pipeline automates the build, testing, and deployment process, reducing manual deployment efforts.
- Containerization with Docker: Achieved a 20% improvement in deployment efficiency.
- Scalable Deployment with Kubernetes: Increased resource utilization by 30% with Kubernetes deployment and service management.
- Automated CI/CD with Jenkins: Streamlined deployment process, reducing manual deployment efforts by 25%.
- Node.js: Application development
- Docker: Containerization
- Kubernetes: Deployment and scaling
- Jenkins: CI/CD pipeline automation
- Helm: (Optional) Kubernetes templating and configuration
- Dockerization: The Node.js app is containerized using Docker, ensuring consistent deployments.
- Kubernetes: Uses Kubernetes for deployment, resource management, and service orchestration, enabling dynamic scaling.
- Jenkins CI/CD: Automated pipeline for continuous integration and deployment, enhancing efficiency.
- Docker installed
- Kubernetes cluster
- Jenkins set up for CI/CD
- kubectl configured
-
Clone the Repository:
git clone https://github.com/shivam130502/Kubernetes-Based-CI-CD-for-Node.js-Web-App.git cd Kubernetes-Based-CI-CD-for-Node.js-Web-App
-
Build Docker Image:
docker build -t Kubernetes-Based-CI-CD-for-Node.js-Web-App.
-
Push Image to Docker Registry:
docker tag your-app-name your-dockerhub-username/your-app-name docker push your-dockerhub-username/your-app-name
-
Deploy to Kubernetes: Apply Kubernetes deployment and service files to deploy the app.
kubectl apply -f Kubernetes-Based-CI-CD-for-Node.js-Web-App-deployment.yml kubectl apply -f Kubernetes-Based-CI-CD-for-Node.js-Web-App-service.yml
Access the application through the service endpoint provided by Kubernetes. Run the following to check your service:
kubectl get svc your-service-name
- Jenkins Setup:
- Configure a Jenkins pipeline to automate the build, test, and deployment stages.
- Pipeline Configuration:
- Include steps for building the Docker image, pushing it to the registry, and deploying to Kubernetes.
This repository can serve as a reference architecture for building scalable, containerized applications with an automated CI/CD pipeline.
- 20% improvement in deployment efficiency due to containerization.
- 30% better resource utilization through Kubernetes deployment and service management.
- 25% reduction in manual deployment efforts through the Jenkins CI/CD pipeline.
Contributions are welcome! Please open an issue or submit a pull request for any suggestions.
This project is licensed under the MIT License.