Jenkins install in Ubuntu Linux

First, check that you have java installed:

java -version

Then add the jenkins repository, and install via APT:

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’
sudo apt-get update
sudo apt-get install jenkins

If you need Java:

sudo apt-get install default-jre