Monday, July 15, 2019

How To Install Jenkins on CentOS 7.5

How To Install Jenkins on CentOS 7.5


Jenkins is an open source, Java-based automation server that offers
an easy way to set up continuous integration and continuous delivery
(CI/CD) pipeline. Continuous integration (CI) is a DevOps practice in
which team members regularly commit their code changes to the
version control repository, after which automated builds and tests are run.
Continuous delivery (CD) is a series of practices where the code
changes are automatically built, tested and deployed to production.
This tutorial will walk you through the steps of installing Jenkins on
a CentOS 7.5 
system.

Installing Jenkins

To install Jenkins on your CentOS system, follow the steps below:


  1. Jenkins is a Java application, so the first step is to install Java. 
Run the following command to install the OpenJDK 8 package:

sudo yum install java-1.8.0-openjdk-devel

  1. The next step is to enable the Jenkins repository. To do that,
 import the GPG key using the following curl command:

curl --silent --location http://pkg.jenkins-ci.org/redhat-stable/jenkins.repo | sudo tee /etc/yum.repos.d/jenkins.repo
  1. And add the repository to your system with:

sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key

  1. Once the repository is enabled, install the latest stable version of Jenkins by 
sudo yum install jenkins

  1. After the installation process is completed, start the Jenkins service with:
sudo systemctl start jenkins

  1. To check whether it started successfully run:
systemctl status jenkins

You should see something similar to this:
jenkins.service - LSB: Jenkins Automation Server
   Loaded: loaded (/etc/rc.d/init.d/jenkins; bad;
vendor preset: disabled)
   Active: inactive (dead)
     Docs: man:systemd-sysv-generator(8)

  1. Finally enable the Jenkins service to start on system boot.

sudo systemctl enable jenkins

Setting Up Jenkins

To set up your new Jenkins installation, open your browser and type your domain or IP address followed by port 8080:
http://your_ip_or_domain:8080


A screen similar to the following will appear, prompting you to enter the Administrator password that is created during the installation:



Use the following command to print the password on your terminal:

sudo cat var/lib/jenkins/secrets/initialAdminPassword

You should see a 32-character long alphanumeric password as shown below:
26edb1bd4ff74e69ba1bb2821a7ad52d

Copy the password from your terminal, paste it into the Administrator password field and click Continue.




On the next screen, you will be asked whether you want to install the suggested plugins or to select specific plugins. Click on the Install suggested plugins box, and the installation process will start immediately.


Once the installation is complete, you will be prompted to set up the first administrative user. Fill out all required information and click Save and Continue.

On the next page, you will be asked to set the URL for the Jenkins instance. The URL field will be populated with an automatically generated URL.
To complete the setup confirm the URL by clicking on the Save and Finish button.


Finally, click on the Start using Jenkins button and you will be redirected to the Jenkins dashboard logged in as the admin user you have created in one of the previous steps.

If you’ve reached this point, you’ve successfully installed Jenkins on your CentOS system.

3 comments:

  1. If you are looking for noteworthy solutions in the field of AWS technology, I recommend you look at this page https://pro4people.com/aws-cloud-solutions/ . You can really get a lot of information on this topic here, and if you want to implement this technology at home, you can also count on professional help

    ReplyDelete
  2. I prefer AWS Cloud Solutions,visit link if you need professional help.

    If you don't know what its Amazon Web Services ? Team Pro4people will explain everything to you.

    ReplyDelete
  3. Great Article. I found so many interesting stuff in your blog especially its discussionvisit site

    ReplyDelete

Ethical Hacking Techniques: Cracking WPA/WPA2 Wi-Fi Using WPS and Capturing Handshakes

In the realm of cyber security, ethical hacking plays a crucial role in identifying and addressing vulnerabilities. One of the areas where e...