CI-CD e2e  Pet-clinic

CI-CD e2e Pet-clinic

E2E Continuous integration (CI) & Continuous Delivery (CD) Pipeline

Required Tools and Technologies

  1. Git & GitHub

    Git is a version control system that manages and keeps track of Source code. GitHub, on the other hand, is a service that lets you host, share, and manage your code files on the internet

  2. Jenkins

    Jenkins is an open-source automation server that allows you to automate various tasks in your software development workflow, such as building, testing, and deploying applications. It provides a web-based interface and supports a wide range of plugins for integrating with different tools and technologies.

  3. Maven

    Maven is a powerful build automation and dependency management tool used primarily for Java projects, although it can be used for projects in other programming languages as well. It provides a comprehensive set of features to help manage the software development lifecycle and simplify the build process

  4. Nexus

    Nexus Repository Manager is a popular artifact repository management tool often used in DevOps environments. It serves as a central hub for storing and managing software artifacts such as binary files, libraries, and dependencies. The Nexus Repository Manager provides version control, access control, and distribution capabilities, making it easier for development and operations teams to collaborate on building and deploying software. By having a centralized repository, teams can ensure consistency, traceability, and efficient sharing of artifacts across the software development lifecycle

  5. SonarQube

    SonarQube is an open-source platform that provides static code analysis and code quality management. It is designed to help developers and development teams identify and fix code issues early in the software development lifecycle. SonarQube analyzes source code for bugs, vulnerabilities, code smells, and code duplications, and provides detailed reports with actionable insights.

  6. OWASP Dependency check

    OWASP The Open Web Application Security Project (OWASP) Dependency-Check is a software composition analysis (SCA) tool that identifies project dependencies with known vulnerabilities. It helps developers and security professionals identify and mitigate potential risks associated with using vulnerable libraries and components

  7. Docker

    Docker is an open-source platform that allows you to automate the deployment, scaling, and management of applications using containerization. Containers provide a lightweight and portable way to package applications and their dependencies, enabling them to run consistently across different environments.

  8. Tomcat webserver

    Apache Tomcat, often referred to simply as Tomcat, is an open-source web server and servlet container developed by the Apache Software Foundation. It is one of the most popular Java-based web application servers used for deploying and running Java servlets and JavaServer Pages (JSP).

    Tomcat is designed to be lightweight and easy to use, making it a popular choice for developers and organizations looking to deploy Java web applications. Tomcat is widely used in both development and production environments and is compatible with various operating systems, including Windows, Linux, and macOS.

Required Plugins for Jenkins

jdk

eclipse temurin installer

openJDK-native-plugin

owasp

owasp dependency check

Docker

Docker

docker pipeline

docker-build-step

cloudbees docker build and publish

sonarqube

sonarqube scanner

Config File Provider plugin -- For nexus

Nexus Integration with Jenkins

install the Config File Provider plugin under the available plugin section

Tomcat Server

the default port of the Tomcat server is 8080

Jenkins & SonarQube Integration

default login credentials for Sonarqube are

username: admin

Password: admin

configure the Sonarqube server to the Jenkins

manage Jenkins >> Configure System >> Add SonarQube

Generate a token under the security section

add Jenkins credentials and use the sonarQube token as a secret text.

configure the Sonarqube server under Jenkins system configuration Provide URL along with port 9000

if the build is success we will get sonarqube analysis report like this

OWASP Dependency-Check Report

Build artifacts in nexus

Docker image on Docker Hub repository

once the build is successful Jenkins pipelines look like this

full stage view of Jenkins pipeline

once the build is successful browse the instance public with port 8080 for the Tomcat server

for the source code check out the below GitHub URL

https://github.com/Raghava0684/Petclinic-Project-2.git

for the Jenkins file check out the below GitHub URL

https://github.com/Raghava0684/petclinic-jenkinsfile/blob/main/Petclinic%20E2E%20%20Project-jenkins%20file

Thank you so much for reading my blog...๐Ÿ˜Š!!!

ย