You can refer this official document to install jenkins in your system: https://www.jenkins.io/doc/
open your favourable linux system and update the packages installed in it
and firstly check wether yum is configured or not(because using it after some time makes it un configured sometime so do check and if it is unconfigured then do check how to configure yum, above file consist of a document in which it has been shown how to configure yum)
using the following command:
sudo dnf update -y --nobest
now install wget command using the following command:
sudo yum install wget
Now run the following cmd
sudo wget -O /etc/yum.repos.d/jenkins.repo https://pkg.jenkins.io/redhat-stable/jenkins.repo
sudo rpm --import https://pkg.jenkins.io/redhat-stable/jenkins.io.key
sudo yum install jenkins java-11-openjdk-devel
note: it'll take some time to install jenkins in your system
Now check jenkins status usng command :
systemctl status jenkins
Now to start jenkins use the following command:
systemctl start jenkins
to open jenkins... disable your firewall from the vm and write your local host ip with port no. 8080 as url to open it..
and then the very next step is to find its password.. so for that.. copy the path given there in the page..
and the next step is to paste that path in your linux.. and write the following amd to show your password
sudo cat /var/lib/jenkins/secrets/initialAdminPassword
click on install plugin
And now create your username and set password according to you:
AND THATS ALL THIS COMPLETES JENKINS SETUP... (❁´◡`❁)