Jenkins环境搭建&基础配置
2015-11-30 14:03
435 查看
环境: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-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 *
相关文章推荐
- [LeetCode]Surrounded Regions
- 【python游戏编程之旅】第五篇---嗷大喵爱吃鱼小游戏开发实例
- AJAX读取日期
- Java进阶思考
- linux基础命令学习之cp(4)
- 黑马程序员—Java基础—File类
- 虚拟机检测技术剖析
- Xcode7 下的 URL scheme 的使用注意事项
- EventBus的使用详解(一)--初步使用EventBus
- [Javascript Practice] 正则表达式 以及 其他小练习
- Python中函数式使用
- Android应用如何支持屏幕多尺寸多分辨率问题
- 栈学习笔记
- CGI编程、SMTP发送邮件(快速入门篇)
- centos 7安装kubernetes集群
- AppDelegate中的方法说明
- VS2008中添加Splash screen控件
- Ubuntu系统重装后必做的事
- error c2678解决方法
- 最最最重要的内容!!!!!!