How to Install Jenkins on Debian 9 Stretch Linux


The objective is to install Jenkins on Debian 9.

Operating System and Software Versions

  • Operating System: – Debian 9 Stretch
  • Software: – Jenkins 2.46.3


Privileged access to your Debian system will be required.




  • # – requires given linux commands to be executed with root privileges either directly as a root user or by use of sudo command
  • $ – requires given linux commands to be executed as a regular non-privileged user


Inlcude Jenkins APT repository

First step is to include Jenkins APT repository and key. Let’s start by adding a new key:

# wget -q -O - | apt-key add 

Next, add a repository. Here we have two options. First, we can add a stable LTS Jenkins repository:

# echo "deb binary/" > /etc/apt/sources.list.d/jenkins.list

Another option is to inlcude latest Jenkins version repository:

# echo "deb binary/" > /etc/apt/sources.list.d/jenkins.list

With that done, update repository index:

# apt update

Install Jenkins

Now, that APT repositories are in place, the installation of Jenkins is rather simple one-liner:

# apt install jenkins

Access Jenkins

Jenkins is now installed. Rertieve your initial Jenkins password:

# cat /var/lib/jenkins/secrets/initialAdminPassword

Once you have your password, navigate your browser to http://jenkins-server-IP:8080 and proceed with additional wizard customisation.

jenkins install debian stretch 9