Install Jenkins on Amazon Linux (AWS)


In this article, we will see how to install Jenkins on Amazon Linux EC2 instance, before that let’s know what is Jenkins, what is its purpose and why it is the most widely used CI/CD tool

What is Jenkins: The leading open source automation server, Jenkins provides hundreds of plugins to support building, deploying and automating any project. In short, it’s a Continuous Integration server.

What is it used for ?? 

It’s a Continuous Integration tool where its tasks are to take care of Continuous Deployment/Delivery. Makes deployment a non-issue and helps you speed up your development other advantages are :

Developer time is focused on work that matters — Much of the work of frequent integrations is handled by automated build and testing systems, meaning developer time isn’t wasted on large-scale error-ridden integrations.

Software quality is improved — Any issues are detected and resolved almost immediately, keeping software in a state where it can be safely released at any time.

Faster Development – Integration costs are reduced both because serious integration issues are less likely and because much of the work of integration is automated.

Most companies who employ continuous integration use their own cloud-based continuous integration servers built on applications like Jenkins.

Here is a graphical representation of how Jenkins work :



So lets get started with the installation of Jenkins on Amazon Linux :


Step 1.  Launch an instance (Amazon Linux) 

Step 2.  Login to the instance, install and setup java environment 

sudo yum install -y git  java-1.8.0-openjdk-devel aws-cli

sudo alternatives --config java

In this command change version of java to the latest version.

Step 3. Install Apache Maven 

sudo wget -O /etc/yum.repos.d/epel-apache-maven.repo

sudo sed -i s/\$releasever/6/g /etc/yum.repos.d/epel-apache-maven.repo

sudo yum install -y apache-maven

mvn –v

Step 4.  Install Jenkins 

sudo wget -O /etc/yum.repos.d/jenkins.repo

sudo rpm --import

sudo yum install jenkins

sudo service jenkins start

sudo chkconfig --add jenkins

That’s it! Now you can go to URL http://<instance ip>:8080

If you’re unable to see the Jenkins page, check security groups restrictions. You can also change the port for Jenkins manually if you want to run it on a different port.

Step 5. Setup Jenkins

This is the first screen you will after going to http://<instance ip>:8080


go to file/var/lib/jenkins/secrets/initialAdminPassword , copy the password and paste it in “administrator password” input box. Then press continue.


On this page select default option “Install suggested plugins”

Next, you will see above the screen. Select install suggested plugins.

Select plugins to install

Next, it will ask for admin credential. You can skip this step and click on continue as admin or you can fill in the required information.



Jenkins will be installed.. you will see a welcome page something like this.

Welcome page


That’s it!  you’ve successfully installed Jenkins on Amazon Linux (AWS)

Please comment below your queries and I’ll surely love to help out.

Credits: Kriti Singh (LinkedIn)

Hope this helps!



Blogger & Assc Cloud Architect

2 comments On Install Jenkins on Amazon Linux (AWS)

Comments are closed.

Site Footer

%d bloggers like this: