So, in the previous post, we have discussed how to install Jenkins on CentOS servers. Here, I will take you through the steps to install Jenkins on Ubuntu servers. I am doing this setup on a Ubuntu 18.04 box.
Install Jenkins on Ubuntu
Step 1: Update packages list
Do an apt-get update on your Ubuntu system to update the package lists.
sudo apt-get update
Step 2: Install Java
Now, install Java on the server.
sudo apt-get install -y openjdk-8-jdk
Step 3: Add Jenkins repo to the server
Add Jenkins apt repository to the server.
wget -q -O - https://pkg.jenkins.io/debian/jenkins.io.key | sudo apt-key add - sudo sh -c 'echo deb http://pkg.jenkins.io/debian-stable binary/ > /etc/apt/sources.list.d/jenkins.list'
Step 4: Install Jenkins
Do an apt-get update and proceed with Jenkins installation.
sudo apt-get update sudo apt-get install jenkins
Once the installation went well, you can start Jenkins using the following command:
systemctl start jenkins
You can now access the Jenkins using http://<ip_address>:8080/
The default Jenkins admin password will be stored in the below file.
Install the suggested plugins on the next page.
Once the plugins are installed, go ahead and create your Jenkins Admin User.
That’s it. The setup is complete. Jenkins is ready to use.
Check out the Jenkins Homepage on the below screenshot:
That’s it. Any issues while installing Jenkins? Please leave a comment below.