一、配置內容安全策略(配置一次):html
1.一、構建一個自由風格的軟件項目 1.二、Build Triggers:Build when job nodes start 1.三、Build:Execute system Groovy script 1.3.一、Groovy Script:System.setProperty("hudson.model.DirectoryBrowserSupport.CSP", "") 1.四、保存,點擊當即構建運行一次,之後每次重啓 Jenkins 會自動運行
二、自動化測試運行node
2.一、構建一個自由風格的軟件項目 2.二、Source Code Management:Subversion/git 2.2.一、Repository URL:http://111.111.111.111:81/svn/autotest_web_ui 2.2.二、Credentials:添加用戶名與密碼 2.2.三、Check-out Strategy:Always check out a fresh copy 2.三、Build Triggers:定時構建 2.3.一、Schedule:分 時 日 月 星期 H H(21-23) * * * 2.四、Build Environment:Delete workspace before build starts 2.五、Build:執行 shell 2.5.一、Command:(python3 須要使用絕對路徑:which python3) cd ${WORKSPACE} /usr/local/bin/python3 run.py 2.六、Post-build Actions: 2.6.一、Publish HTML reports 2.6.1.一、HTML directory to archive:${WORKSPACE}/report 2.6.1.二、Index page[s]:test.html 2.6.1.三、Report title:自動化測試報告 2.6.1.四、勾選:Keep past HTML reports 2.6.二、歸檔成品 2.6.2.一、Files to archive:** 2.七、集成發送構建信息至釘釘: 2.7一、添加 Jenkins URL 2.7二、添加釘釘羣機器人token