1. Preparation premise
JDK is already installed
echo $PATH
Create a soft link to the configuration according to your jdk installation path
ln -s /java/jdk1.8.0_231/bin/java /usr/bin/java
The machine has been networking
Uninstall jenkins (if you have it installed skip)
sudo apt-get remove jenkins sudo apt-get purge jenkins sudo apt-get purge --auto-remove jenkins
2. Complete the installation by following command
wget -q -O - https://pkg.jenkins.io/debian/jenkins-ci.org.key | sudo apt-key add - sudo sh -c 'echo deb http://pkg.jenkins.io/debian-stable binary/ > /etc/apt/sources.list.d/jenkins.list' sudo apt-get update sudo apt-get install jenkins
3. Start jenkis
sudo /etc/init.d/jenkins [start|restart|stop]
4. Review the installation password
cat /var/lib/jenkins/secrets/initialAdminPassword
5. Open the browser http://192.168.215.50:8080 (if the server upload too tomcat, change the port's jenkins)
Sudo vi $ / etc / default / jenkins # modify the following HTTP_PORT = 8085 # restart jenkins service $ sudo /etc/init.d/jenkins restart
Just enter the password query
6. Select recommend to install the plug
Patiently waiting for installation
7. Create the first administrative account