Jenkins installation and troubleshooting errors

  • System: win10

First, install

1. Download

Jenkins官网
Here Insert Picture Description

2, installation

Here only mounting war package
1Or you can enter the store directory Jenkins on the command line using other methods
Here Insert Picture Description
2Command line input

java -jar jenkins.war

3, Successful start

Here Insert Picture Description

4, Direct your browser to http: // localhost: 8080

3, simple to use

Second, Troubleshooting

1, install the plug slowly and failure rate

Choose to install the plug-in site, choose one

http://mirror.xmission.com/jenkins/updates/update-center.json   # 推荐
http://mirrors.shu.edu.cn/jenkins/updates/current/update-center.json
https://mirrors.tuna.tsinghua.edu.cn/jenkins/updates/update-center.json
http://updates.jenkins.io/update-center.json 

Modify the following address, you can restart
Here Insert Picture Description

2, can not be restarted

When you type in the browser: HTTP: // localhost: 8080 / restart will appear the following message.

Jenkins cannot restart itself as currently configured

(3) At this point you need to "Install as Windows service"

1, System settings:Here is a quote
2Click on:Install as Windows serviceHere Insert Picture Description
3Click: install
Here Insert Picture Description
reboot after a good set up Jenkins

3, Install as Windows service: Failed

1, A message appears

AccessDenied

2, Right click and select PropertiesHere Insert Picture Description
3Compatibility: Run as administratorHere Insert Picture Description

3、ModuleNotFoundError: No module named ‘XXX’

(1), at the top of the script file to add the following code


import sys
sys.path.append(r"D:\Workspaces\Pworkspace")

(2), but it does not meet code specifications PEP8 using autopep8 will be two lines of code on the bottom of all references, tried to do so will cause a run error
Here Insert Picture Description

4、configparser.NoSectionError: No section: ‘xxx’

(1), using code like this relative path, an error will be required to change the absolute path

path = "../config/LocalElement.ini"
path = "D:/Workspaces/Pworkspace/config/LocalElement.ini"

5, thanks changyixue Bowen

Bowen link

Published 59 original articles · won praise 6 · views 10000 +

Guess you like

Origin blog.csdn.net/qq_27009225/article/details/104807816
Recommended