Jenkins setup on AWS

Jenkins is a Continuous Integration (CI) apparatus or server which is composed in java language. Jenkins gave continuous integration administrations to programming improvement, which can be begun by means of web application server or command line. Continuous Integration is a procedure that expects engineers to incorporate code into a mutual repository. Jenkins is free programming to download and introduce. Java 8 ought to be present, if not please utilize the beneath ventures for that to introduce.

Install JAVA 8

yum install wget ( in case wget is not found)

$ wget –header “Cookie: oraclelicense=accept-securebackup-cookie”

$ sudo yum localinstall jdk-8u161-linux-x64.rpmexport JAVA_HOME=/usr/java/jdk1.8.0_161/
export JRE_HOME=/usr/java/jdk1.8.0_161/jre


export PATH
sudo alternatives –config java

Install Jenkins

sudo yum update
sudo wget -O /etc/yum.repos.d/jenkins.repo
sudo rpm –import
sudo yum install jenkins
sudo service jenkins start

Here we can use Gradle as the build tool and the GitHub as the source code repository. Each focus on GitHub naturally triggers the Jenkins assemble, which utilizes Gradle to incorporate Java code, run unit tests, and play out extra checks (code scope, static code investigation, etc). After the Jenkins assemble is finished, a warning is sent to the designers.

Install Git on Jenkins server

yum install git

Open the URL in the web browser. The default port is 8080


It will ask for the initial password, please run the below command

cat /var/lib/jenkins/secrets/initialAdminPassword

Configure Jenkins with JAVA_HOME, MAVEN_HOME

Go to Manage Jenkins -> Global Tool Configuration

Add JDK -> JAVA_HOME -> put the java_home path of the machine

Add MAVEN -> Select Install automatically.