Jenkins is an open source platform that supports tasks such as automated construction and deployment. Basically, it can be said that it is an indispensable tool for continuous integration (CI) and continuous release (CD).
CentOS 7 install JAVA environment (JDK 1.8)
yum install git
yum install maven
yum install jenkins
Modify the jenkins startup script
vi /etc/init.d/jenkins
Modify candidates to add java optional path:
candidates="
/usr/java/jdk1.8.0_181/bin/java
"
Start Jenkins and set Jenkins to boot
# Reload service (make the modified Jenkins startup script take effect)
systemctl daemon-reload
# Start the Jenkins service
systemctl start jenkins
# Start the Jenkins service
systemctl stop jenkins
# Set the Jenkins service to start on boot
# Since Jenkins is not a Native Service, you need to use the chkconfig command instead of the systemctl command
sudo /sbin/chkconfig jenkins on
Query Jenkins default password
cat /var/lib/jenkins/secrets/initialAdminPassword
After entering the password, install the recommended plugin
Add admin user
Configure Jenkins URL
Start using Jenkins
Start Jenkins
service jenkins start
Shut down Jenkins
service jenkins stop
Query the Jenkins installation path
whereis jenkins
Recommended Posts