You are on page 1of 3

Jenkins

What’s Jenkins
Jenkins is a popular open source tool to perform continuous integration and build
automation. The basic functionality of Jenkins is to execute a predefined list of steps, e.g. to
compile Java source code and build a JAR from the resulting classes. The trigger for this
execution can be time or event based.

Why Jenkins

Jenkins is a software that allows continuous integration. Jenkins will be installed on a server
where the central build will take place. The following flowchart demonstrates a very simple
workflow of how Jenkins works.

Along with Jenkins, sometimes, one might also see the association of Hudson. Hudson is a very
popular open-source Java-based continuous integration tool developed by Sun Microsystems

Dev0ps Krishna 1
which was later acquired by Oracle. After the acquisition of Sun by Oracle, a fork was created
from the Hudson source code, which brought about the introduction of Jenkins.

What’s Continuous Integration(CI)

Continuous Integration is a development practice that requires developers to integrate


code into a shared repository at regular intervals. This concept was meant to remove the problem
of finding later occurrence of issues in the build lifecycle. Continuous integration requires the
developers to have frequent builds. The common practice is that whenever a code commit
occurs, a build should be triggered.

Advantages of Jenkins
 It is an open source tool with great community support.
 It is easy to install.
 It has 1000+ plugins to ease your work. If a plugin does not exist, you can code it and
share with the community.
 It is built with Java and hence, it is portable to all the major platforms.
 With Jenkins you can build snapshots and release artifacts of your application.
 It is also used for deployment of released artifact with custom scripts.
 It provides continuous integration pipeline support for establishing software
development life cycle work flow for your application.
 It also provides support for scheduled builds & automation test execution.
 You can configure Jenkins to pull code from a version control server like SVN, Git,
etc. whenever a commit is made.
 It can execute bash scripts, shell scripts, ANT and Maven Targets.
 It can be used to Publish results and send email notifications.

Jenkins Installation

Pre-requisites: Jdk, Tomcat,

Jdk(Java) installation

 Extract the java tar file in Linux to a directory


 tar xzvf jdk-7u79-linux-x64.tar –C /java
 Set Java PATH in ~/.bash_profile file
 export JAVA_HOME=/java
 export PATH=$JAVA_HOME/bin:$PATH

Dev0ps Krishna 2
Tomcat Installation

 Extract the tomcat tar file in Linux to a directory


 tar xzvf apache-tomcat-8.0.26.tar –C /tomcat
 Set Java PATH in ~/.bash_profile file
 export CATALINA_HOME=/tomcat
 export PATH=$CATALINA_HOME/bin:$PATH
 check ps –ef | grep tomcat
 start tomcat from /tomcat/bin/
 ./startup.sh
 Stop from /tomcat/bin
 ./shutdown.sh

Jenkins installation
 download the jenkins.war file
 can be deployed either through tomcat home page or
 copy the jenkins.war into /tomcat/webapps directory

Dev0ps Krishna 3

You might also like