Skip to content

Latest commit

Β 

History

11 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸš€ DevOps CI/CD Pipeline Automation

A complete DevOps CI/CD Pipeline Automation project demonstrating Continuous Integration and Continuous Deployment using Spring Boot, Jenkins, Maven, Docker, GitHub Webhooks, ngrok, Docker Hub, and Vagrant Ubuntu Virtual Machine.

The project automates the entire software delivery lifecycle from code commit to deployment with minimal manual intervention.


πŸ“Œ Project Overview

This project implements a fully automated CI/CD pipeline where source code changes pushed to GitHub automatically trigger Jenkins pipelines, build the application using Maven, create Docker images, push them to Docker Hub, and deploy the application using Docker containers.

The pipeline ensures:

  • Faster software delivery
  • Reduced manual deployment effort
  • Consistent deployment environment
  • Automated build and deployment process
  • Improved software quality

πŸ—οΈ Architecture Diagram

CI/CD Pipeline Architecture

CI/CD Pipeline


Deployment Workflow Architecture

Deployment Workflow


πŸ› οΈ Technology Stack

Technology Purpose
Spring Boot Backend Application
Java Programming Language
Maven Build Automation
Jenkins CI/CD Automation
Docker Containerization
GitHub Source Code Management
GitHub Webhooks Pipeline Triggering
ngrok Public Tunnel
Docker Hub Container Registry
Vagrant VM Provisioning
Ubuntu VM Deployment Environment

✨ Key Features

Continuous Integration

  • Automated source code integration
  • GitHub repository monitoring
  • Jenkins build automation
  • Maven project compilation
  • Automated testing workflow

Continuous Deployment

  • Docker image generation
  • Docker Hub image push
  • Automated deployment
  • Containerized application delivery

DevOps Automation

  • GitHub Webhook integration
  • Jenkins Pipeline automation
  • Docker deployment workflow
  • End-to-end CI/CD implementation

πŸ“‚ Project Structure

DevOps-CI-CD-Pipeline/
β”‚
β”œβ”€β”€ src/
β”‚   └── main/
β”‚       β”œβ”€β”€ java/
β”‚       β”‚   └── HelloController.java
β”‚       β”‚
β”‚       └── resources/
β”‚           └── static/
β”‚               └── images/
β”‚                   β”œβ”€β”€ pipeline.png
β”‚                   β”œβ”€β”€ workflow.png
β”‚                   β”œβ”€β”€ img1.png
β”‚                   β”œβ”€β”€ img2.png
β”‚                   └── ...
β”‚
β”œβ”€β”€ Dockerfile
β”œβ”€β”€ Jenkinsfile
β”œβ”€β”€ pom.xml
β”œβ”€β”€ README.md
β”‚
└── target/

βš™οΈ CI/CD Workflow

Developer
    β”‚
    β–Ό
GitHub Push
    β”‚
    β–Ό
GitHub Webhook
    β”‚
    β–Ό
ngrok Tunnel
    β”‚
    β–Ό
Jenkins Pipeline
    β”‚
    β”œβ”€β”€ Source Checkout
    β”œβ”€β”€ Maven Build
    β”œβ”€β”€ Unit Testing
    β”œβ”€β”€ Docker Build
    β”œβ”€β”€ Docker Push
    └── Deployment
    β”‚
    β–Ό
Docker Container
    β”‚
    β–Ό
Spring Boot Application

πŸš€ Pipeline Stages

Stage 1: Source Control

Developer pushes code changes to GitHub.

git add .
git commit -m "Updated application"
git push origin main

Stage 2: Webhook Trigger

GitHub automatically sends a webhook request to Jenkins.


Stage 3: Build Process

Jenkins executes Maven build commands.

mvn clean package

Stage 4: Docker Image Build

docker build -t devops-app .

Stage 5: Docker Hub Push

docker push username/devops-app

Stage 6: Deployment

docker run -d -p 8080:8080 devops-app

🐳 Docker Commands

Build Docker Image

docker build -t devops-app .

List Docker Images

docker images

Run Docker Container

docker run -d -p 8080:8080 devops-app

Check Running Containers

docker ps

Stop Container

docker stop <container-id>

Remove Container

docker rm <container-id>

πŸ”§ Jenkins Pipeline Workflow

Checkout Source Code
        β”‚
        β–Ό
Build Project (Maven)
        β”‚
        β–Ό
Run Tests
        β”‚
        β–Ό
Create Docker Image
        β”‚
        β–Ό
Push Image To Docker Hub
        β”‚
        β–Ό
Deploy Container
        β”‚
        β–Ό
Application Available

🌐 ngrok Configuration

Expose Jenkins Server:

ngrok http 8080

Example:

https://abc123.ngrok-free.app

Used to receive GitHub webhook requests.


πŸ“‘ GitHub Webhook Configuration

Webhook URL:

http://<ngrok-url>/github-webhook/

Content Type:

application/json

Trigger:

Push Event

πŸš€ Running the Project

Clone Repository

git clone https://github.com/your-username/your-repository.git
cd your-repository

Build Application

mvn clean package

Run Application

mvn spring-boot:run

Access Application

http://localhost:8080

Health Endpoint

http://localhost:8080/health

Response:

APPLICATION UP

Version Endpoint

http://localhost:8080/version

Response:

Version 2.0.0

πŸ“Š Project Statistics

Metric Value
Pipeline Automation 100%
Technologies Used 8+
Deployment Type Containerized
CI/CD Workflow Automated
Screenshots Captured 55+
Build Tool Maven
Container Platform Docker
CI/CD Server Jenkins

🎯 Learning Outcomes

Through this project, the following DevOps concepts were implemented and explored:

  • Continuous Integration (CI)
  • Continuous Deployment (CD)
  • Jenkins Automation
  • GitHub Webhooks
  • Docker Containerization
  • Docker Hub Registry
  • Build Automation using Maven
  • Infrastructure Virtualization using Vagrant
  • Ubuntu Server Administration
  • Deployment Automation

πŸ‘¨β€πŸ’» Author

Komal Joshi

B.Tech Computer Science Engineering

DevOps | Cloud | Full Stack Development | Software Engineering


⭐ Acknowledgement

This project was developed to demonstrate practical implementation of modern DevOps practices including CI/CD automation, containerization, deployment orchestration, and infrastructure provisioning using industry-standard tools.


⭐ If you found this project useful, consider giving it a star on GitHub.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages