Installing Jenkins on Debian is a trivial task – a package is available, through aptitude, and default configuration is sufficient. This tutorial does not cover advanced security topics. By default, port 8080 is open and no authentication required – this poses a major security risk; thus if you rely solely on the instructions below, you should not expose your Jenkins server on an external network. Basic authentication instructions are provided. Root level access is required.
NOTE: This article relies heavily on instructions found here: http://pkg.jenkins-ci.org/debian/
1. Add the Jenkins repository key:
wget -q -O - http://pkg.jenkins-ci.org/debian/jenkins-ci.org.key | sudo apt-key add -
2. Append the following repository to /etc/apt/sources.list:
deb http://pkg.jenkins-ci.org/debian binary/
3. Update the package index: apt-get update 4. Install Jenkins:
apt-get install jenkins
5. Start the Jenkins service:
service jenkins start
Next part describes how enabled basic authentication, using Jenkins’ user database. More details about Jenkins user authentication models are available here.
1. Open your Jenkins instance, available here:
http://hostname:8080/
2. Click Manage Jenkins, and open:
‘Configure Global Security’
3. Click ‘Enable Security’, where you should see something similar to:
4. Select the following options:
Security realm: Jenkins’ own user database Authorization: Anyone can do anything
5. Click ‘Save’, followed by ‘Sign Up’, and fill in the following form:
6. Login using the new user.
NOTE: This authentication model allows anyone to create a new user, and once logged in, perform any type of actions.