• Categories
    Category
  • Categories
    Category
  • News
  • Tutorials
  • Forums
  • Tags
  • Users
Tutorial Comments FAQ Related Articles

How To Install and Use Jenkins in Ubuntu

869

To Install and Use Jenkins on Ubuntu

Jenkins is an open source automation server and continuous integration tool. It can be used for building and testing software projects. It provides lots of deploying and automating plugins. This articles gives a clear picture about the installation and the usage of Jenkins in Ubuntu.


Installation of Jenkins

The installation of Jenkins requires adding the key. Run the following command for the same.

root@linuxhelp1:~# wget -q -O - https://jenkins-ci.org/debian/jenkins-ci.org.key | sudo apt-key add -
OK

Once the key is added, it is essential to add the repository too. It can be done with the following command.

root@linuxhelp1:~# sh -c ' echo deb http://pkg.jenkins-ci.org/debian binary/ >  /etc/apt/sources.list.d/jenkins.list' 

After adding the repository, update it by triggering the following command.

root@linuxhelp1:~# apt-get update
Hit:1 http://in.archive.ubuntu.com/ubuntu xenial InRelease
Hit:2 http://security.ubuntu.com/ubuntu xenial-security InRelease                                              
Hit:3 http://in.archive.ubuntu.com/ubuntu xenial-updates InRelease                                    
Hit:4 http://in.archive.ubuntu.com/ubuntu xenial-backports InRelease                                  
Ign:5 http://pkg.jenkins-ci.org/debian binary/ InRelease                 
Get:6 http://pkg.jenkins-ci.org/debian binary/ Release [2,042 B]
Get:7 http://pkg.jenkins-ci.org/debian binary/ Release.gpg [181 B]
Get:8 http://pkg.jenkins-ci.org/debian binary/ Packages [1,036 B]
Fetched 3,259 B in 1s (1,777 B/s)
Reading package lists... Done
W: http://pkg.jenkins-ci.org/debian/binary/Release.gpg: Signature by key 150FDE3F7787E7D11EF4E12A9B7D32F2D50582E6 uses weak digest algorithm (SHA1)

Now is the time for installing Jenkins. Invoke the following command for the same.

root@linuxhelp1:~# apt-get install jenkins -y
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  ca-certificates-java daemon default-jre-headless java-common openjdk-8-jre-headless
Suggested packages:
  default-jre openjdk-8-jre-jamvm fonts-dejavu-extra fonts-ipafont-gothic fonts-ipafont-mincho
  ttf-wqy-microhei | ttf-wqy-zenhei fonts-indic
The following NEW packages will be installed:
  ca-certificates-java daemon default-jre-headless java-common jenkins openjdk-8-jre-headless
0 upgraded, 6 newly installed, 0 to remove and 416 not upgraded.
Need to get 96.1 MB of archives.
After this operation, 170 MB of additional disk space will be used.
Get:1 http://in.archive.ubuntu.com/ubuntu xenial/main amd64 java-common all 0.56ubuntu2 [7,742 B]
Get:2 http://in.archive.ubuntu.com/ubuntu xenial/main amd64 default-jre-headless amd64 2:1.8-56ubuntu2 [4,380 B]
Get:3 http://in.archive.ubuntu.com/ubuntu xenial/main amd64 ca-certificates-java all 20160321 [12.9 kB]
Get:4 http://in.archive.ubuntu.com/ubuntu xenial-updates/main amd64 openjdk-8-jre-headless amd64 8u111-b14-2ubuntu0.16.04.2 [26.9 MB]
Get:5 http://pkg.jenkins-ci.org/debian binary/ jenkins 2.28 [69.1 MB]                               
Get:5 http://pkg.jenkins-ci.org/debian binary/ jenkins 2.28 [69.1 MB]                                          
Get:5 http://pkg.jenkins-ci.org/debian binary/ jenkins 2.28 [69.1 MB]                                          
Get:5 http://pkg.jenkins-ci.org/debian binary/ jenkins 2.28 [69.1 MB]                                          
Get:5 http://pkg.jenkins-ci.org/debian binary/ jenkins 2.28 [69.1 MB]                                          
Get:5 http://pkg.jenkins-ci.org/debian binary/ jenkins 2.28 [69.1 MB]                                          
Get:5 http://pkg.jenkins-ci.org/debian binary/ jenkins 2.28 [69.1 MB]              
.
.
.
Adding debian:GeoTrust_Primary_Certification_Authority.pem
Adding debian:Swisscom_Root_EV_CA_2.pem
Adding debian:CA_Disig_Root_R1.pem
Adding debian:OISTE_WISeKey_Global_Root_GA_CA.pem
Adding debian:CA_WoSign_ECC_Root.pem
Adding debian:Camerfirma_Chambers_of_Commerce_Root.pem
Adding debian:SwissSign_Platinum_CA_-_G2.pem
Adding debian:Go_Daddy_Class_2_CA.pem
Adding debian:AddTrust_Public_Services_Root.pem
Adding debian:AC_Raí z_Certicá mara_S.A..pem
Adding debian:E-Tugra_Certification_Authority.pem
Adding debian:Verisign_Class_1_Public_Primary_Certification_Authority_-_G2.pem
Adding debian:certSIGN_ROOT_CA.pem
done.
Setting up default-jre-headless (2:1.8-56ubuntu2) ...
Setting up jenkins (2.28) ...
Processing triggers for ca-certificates (20160104ubuntu1) ...
Updating certificates in /etc/ssl/certs...
0 added, 0 removed  done.
Running hooks in /etc/ca-certificates/update.d...

done.
done.
Processing triggers for ureadahead (0.100.0-19) ...
Processing triggers for systemd (229-4ubuntu4) ...

After the installation, restart the Jenkins service by issuing the following command.

root@linuxhelp1:~# service jenkins restart

The Jenkins service is ready to be accessed. You can launch it by calling the ip address of your machine along with port number 8080 on your browser as follows.

Jenkins-ip-address

Jenkins-unlock

If you see the Getting Started page as above, the next step is to get the admin password. Issue the following command for the same.

root@linuxhelp1:~# cat /var/lib/jenkins/secrets/initialAdminPassword
de6e973e5f7d417e99d908154533aaa8

Now copy the given password from the terminal and paste it on the browser and click continue as follows.

Jenkins-password

Once the password is given you' ll be taken to the installation window as below. Select your desired option to install the plugins. You can either choose to Install suggested plugins or Select required plugins options.

Jenkins-installation-window

Jenkins-plugins

Once the plugins are installed, it is time to create an admin account. To do that, log into Jenkins and click on Continue as admin.

Jenkins-admin-account

Now click on Start using Jenkins

Jenkins-Start

Now you' ll be taken to the home page of the Jenkins as below.

Jenkins-home-page

To install Plugins in Jenkins

For installing plugins navigate to Manage Jenkins > > Manage Plugins > > Available Tab and select the plugins to install.

Jenkins-install-plugins

Jenkins-Manage-Plugins

Jenkins-update-center

To create a new user

If you want to create a new user account, navigate to Manage Jenkins > > Manage Users > > Create User . Enter the required details and click Create User.

Jenkins-Manage-Jenkins

Jenkins-Manage-Users

Jenkins-Create-User

Jenkins-

Jenkins-users

Tags:
jayce
Author: 

Comments ( 0 )

No comments available

Add a comment

Frequently asked questions ( 5 )

Q

Are cluster deployments allowed?

A

Yes, you can deploy to 1 or more clusters using this plugin. The latest version has a button called "Show Available Targets" to help you identify where the plugin is allowed to deploy to. You can deploy to multiple targets as long as each target is on its own line.

Q

Can I deploy to multiple versions of WebSphere?

A

Yes, but only if you use another Jenkins server to deploy to the different version (see FAQ #10 above). If you want to deploy to the same to different WebSphere versions from the same Jenkins server, you can't due to classloader issues between the WebSphere jar versions.

Q

I get an ObjectName error when deploying to WebSphere in Ubuntu?

A

This error typically occurs because of a classloader issue. The latest versions of this plugin have tried to rectify this issue by implementing "false". If you have issues, you can always attempt to change this to "true" in the plugin's manifest.

Q

What is Jenkins on Ubuntu?

A

Jenkins is an open source automation server and continuous integration tool. It can be used for building and testing software projects. It provides lots of deploying and automating plugins.

Q

Why does my test connection connect successfully but my install/upload fail to connect?

A

a)SOAP commands are sent from the WebSphere Deployer Plugin (WDP) on port 8879 (For WAS ND) or port 8880 (For standalone WAS)
b) When the WDP initiates the deployment, the internal WAS environment looks up the common name of the SSL certificate for the deployment manager (or WAS admin console)
c) If the common name (CN) specified in the SSL cert is not found in the DNS, the upload may fail b
) If the CN matches the DNS name of the WebSphere Deployment Manager or Admin Console, the upload will succeed. Sometimes, you will get a Hostname Verification error. If this happens, you need to make sure the CN matches the hostname of the server you are deployment manager (or WAS admin console). If you have this issue, you must regenerate the root certificate and make it match the DNS.

Related Tutorials in How To Install and Use Jenkins in Ubuntu

Related Tutorials in How To Install and Use Jenkins in Ubuntu

How to install Jenkins in Linux
How to install Jenkins in Linux
Jul 6, 2016
How to Install Jenkins on Oracle Linux 8.5
How to Install Jenkins on Oracle Linux 8.5
Oct 18, 2022
How to Install Jenkins using Debian Package on Linux Mint 20
How to Install Jenkins using Debian Package on Linux Mint 20
Apr 16, 2021
How to change the Home Directory of Jenkins in Linux Mint 20
How to change the Home Directory of Jenkins in Linux Mint 20
Apr 24, 2021
How to Manage Jenkins in Linux
How to Manage Jenkins in Linux
Jul 6, 2016
How To Install and Use Jenkins in Ubuntu
How To Install and Use Jenkins in Ubuntu
Nov 11, 2016
How to Install jenkins using .war Package on Linux Mint 20
How to Install jenkins using .war Package on Linux Mint 20
Apr 15, 2021
How To Install Jenkins On Rocky Linux 8.6
How To Install Jenkins On Rocky Linux 8.6
Jul 20, 2022
Back To Top!
Rank
User
Points

Top Contributers

userNamenaveelansari
135850

Top Contributers

userNameayanbhatti
92510

Top Contributers

userNamehamzaahmed
32150

Top Contributers

1
userNamelinuxhelp
31040

Top Contributers

userNamemuhammadali
24500
Can you help Luk Van De Looverbosch ?
How to create a root ?

Hello,
How to create root@linuxhelp in Linux Mint 20.1 64-bit ?
Thanks in advance for your reply.
Best regards.

Networking
  • Routing
  • trunk
  • Netmask
  • Packet Capture
  • domain
  • HTTP Proxy
Server Setup
  • NFS
  • KVM
  • Memory
  • Sendmail
  • WebDAV
  • LXC
Shell Commands
  • Cloud commander
  • Command line archive tools
  • last command
  • Shell
  • terminal
  • Throttle
Desktop Application
  • Linux app
  • Pithos
  • Retrospect
  • Scribe
  • TortoiseHg
  • 4Images
Monitoring Tool
  • Monit
  • Apache Server Monitoring
  • EtherApe 
  • Arpwatch Tool
  • Auditd
  • Barman
Web Application
  • Nutch
  • Amazon VPC
  • FarmWarDeployer
  • Rukovoditel
  • Mirror site
  • Chef
Contact Us | Terms of Use| Privacy Policy| Disclaimer
© 2025 LinuxHelp.com All rights reserved. Linux™ is the registered trademark of Linus Torvalds. This site is not affiliated with linus torvalds in any way.