首页 > 其他 > 详细

Jenkins环境搭建&基础配置

时间:2015-11-30 14:42:08      阅读:305      评论:0      收藏:0      [点我收藏+]
环境:win7
安装包:jenkins-1.638.zip (下载地址:http://jenkins-ci.org/) 
默认安装-->访问地址:     localhost:8080
 
安装插件
系统管理-->管理插件-->可选插件
过滤栏 输入 GitLab
自动安装:
点击直接安装
手动安装:
点击条目 下载.hpi文件
管理插件-->高级-->上传插件
选择文件 点击上传
 
系统设置
系统管理-->系统设置
勾选 Environment variables
     键 ANDROID_NDK_ROOT
     值 D:\android-ndk-r10d
 
     键 ANDROID_SDK_BUILD_TOOLS
     值 D:\adt-bundle-windows-x86_64-20140321\sdk\build-tools\android_4.4.2
 
     键 ANDROID_SDK_ROOT
     值 D:\adt-bundle-winodws-x86_64-20140321\sdk
 
     键 JAVA_HOME
     值 C:\Program Files\Java\jdk1.8.0_31
 
Git
Git installations
     Name                              Default
     Path to Git executable     C:\Program Files (x86)\Git\bin\git.exe
 
Gitlab
     Gitlab host URL          http://gitlab.egret.com
     API Token                  5ATVJGUYyyfdkfuPyH_s
 
创建构建项目
新建-->Item名称-->输入 runtime-launcher-qe-->单选 构建一个自由风格的软件项目-->单击 OK
 
勾选 参数化构建过程
单击 添加参数-->String Parameter
     名字        GIT_URL
     默认值     git@gitlab.egret.com:runtime/runtime-launcher.git
     描述        <font color="red">警告!除非必要,请不要修改此配置!修改该配置,要确保目标git库对liuyuan@egret.com有访问权限。</font>
 
     名字        BRANCH_NAME
     默认值     origin/channels/internal_v2.0
     默认        <font color="red">警告!除非必要,请不要修改此配置!修改该配置,要确保目标branch对liuyuan@egret.com有访问权限。</font>
 
源码管理
     单选 Git
     Repository URL      ${GIT_URL}
    
     Credentials     单击Add
          Kind SSH Username with private key
          Username     liuyuan@egret.com
          Private Key   单选Enter directly-->粘贴私钥内容
          单击 Add
     
     Branches to build     Branch Specifler(blank for ‘any‘) ${BRANCH_NAME}
 
构建
     添加构建步骤-->Invoke Ant
     Ant Version      ant-1.9.6-in-jenkins
     Targets             clean release
     单击 高级
     Build File          EgretRuntimeLauncherInternal/build.xml
     Propertles        sdk.dir=D:\\adt-bundle-windows-x86_64-20140321\\sdk
                             key.store=D:\\adt-bundle-windows-x86_64-20140321\\cert.keystore
                             key.store.password=123456
                             key.alias=cert.keystore
                             key.alias.password=123456
 
构建后操作
     添加构建后操作步骤-->Archive the artifacts
     由于存档的文件     EgretRuntimeLauncherInternal/bin/*.apk
     
     添加构建后操作步骤-->Record fingerprints of files to track usage
     Files to fingerprint     *

Jenkins环境搭建&基础配置

原文:http://www.cnblogs.com/imathliu/p/5006982.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!