1.上傳安裝包 jenkins-1.656-1.1.noarch.rpmhtml
2.安裝jenkinsjava
sudo rpm -ivh jenkins-1.656-1.1.noarch.rpm服務器
3.vi /etc/sysconfig/jenkinsjvm
修改端口JENKINS_PORT="8888" —端口隨意ide
修改運行用戶JENKINS_USER="admin"工具
4.vi /etc/init.d/jenkinspost
添加java路徑~/software/jdk1.7.0_79/bin/java單元測試
candidates="測試
/etc/alternatives/javaui
/usr/lib/jvm/java-1.6.0/bin/java
/usr/lib/jvm/jre-1.6.0/bin/java
/usr/lib/jvm/java-1.7.0/bin/java
/usr/lib/jvm/jre-1.7.0/bin/java
/usr/lib/jvm/java-1.8.0/bin/java
/usr/lib/jvm/jre-1.8.0/bin/java
/usr/bin/java
/home/admin/software/jdk1.7.0_79/bin/java
5.修改jenkins全部者
sudo chown -R admin /usr/lib/jenkins
sudo chgrp -R admin /usr/lib/jenkins
sudo chown -R admin /var/log/jenkins
sudo chgrp -R admin /var/log/jenkins
sudo chown -R admin /var/lib/jenkins
sudo chgrp -R admin /var/lib/jenkins
sudo chown -R admin /var/cache/jenkins
sudo chgrp -R admin /var/cache/jenkins
6.啓動jenkins
sudo service jenkins start
7.訪問jenkins
8.安裝jenkins後「可選插件」列表中顯示爲空
http://www.techv5.com/topic/421/
須要安裝軟件:
Grails
JDK
GIT
TOMCAT
PYTHON,NOSE
須要安裝插件:
Cobertura Plugin 代碼覆蓋率
Grails plugin 編譯工具
JUnit Plugin 單元測試
Python Plugin pyhton腳本
SSH Slaves plugin 遠程登陸節點服務器
Job:
按先後順序執行
build 構建
test 測試(單元,接口,ui)
checkcode 代碼檢查
deploy 部署
觸發條件:
構建 一旦代碼有變更
測試 按實際須要
代碼檢查 一旦代碼有變更
部署 按實際須要