0% found this document useful (0 votes)
5 views7 pages

Create Ci Pipeline Using Jenkins

Create CI Pipeline Using Jenkins

Uploaded by

tamilarasi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views7 pages

Create Ci Pipeline Using Jenkins

Create CI Pipeline Using Jenkins

Uploaded by

tamilarasi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 7

Create CI Pipeline Using Jenkins

Devops (Anna University)

Scan to open on Studocu

Studocu is not sponsored or endorsed by any college or university


Downloaded by Tamilarasi Selvam
EX NO:04

DATE: CREATE CI PIPELINE USING JENKINS

Aim:
Implement a CI pipeline with Jenkins to automate the build and test processes for a sample Java project.

Procedure:
Step 1: Install Required Jenkins Plugins: Install the necessary plugins in Jenkins, such as Git, Maven.

Step 2: Configure Jenkins Credentials: Set up credentials in Jenkins for accessing your version control
system .

Step 3: Create a New Jenkins Job: Open Jenkins and create a new freestyle project or a pipeline job.

Step 4: Configure Source Code Management: Choose the version control system (e.g., Git).

Step 5: Provide the repository URL and credentials.

Step 6: Set Build Triggers: Configure triggers to initiate the build process automatically when changes
are detected in the repository.

Step 7: Configure Build Steps: Define build steps based on your project requirements.

Step 8: Specify the Maven goals, such as clean install.

~mvn clean install

Step 9: Save and Run the Pipeline: Save the Jenkins job configuration.

Step 10: Manually trigger the job to ensure that it runs successfully.

Step 11: Integrate Testing: Integrate testing steps into the pipeline. For example, add additional Maven
goals for running unit tests.

~mvn clean test

Step 12: Customize and Expand: Customize the pipeline according to your project's specific needs.

Downloaded by Tamilarasi Selvam


Screenshot:

1. Create a New Jenkins Job:


• Open Jenkins and click on "New Item."
• Enter a name for the job and select the type (pipeline).

Downloaded by Tamilarasi Selvam


2. Set Build Triggers:
• Scroll down to the "Build Triggers" section.
• Select the option to trigger the build when changes are pushed to the repository.

3. Configure Pipeline Script:


• In the Pipeline Script add Pipeline Script to get executed.

Downloaded by Tamilarasi Selvam


4. Save and Run the Pipeline:
• Save the job configuration.
• Manually trigger the job and verify that the build process runs successfully.

Downloaded by Tamilarasi Selvam


Output:
Result:
The above procedure is executed and the output is verified successfully.

Downloaded by Tamilarasi Selvam ([email protected])

You might also like