老李分享:持续集成学好jenkins之内置命令

 

Jenkins命令调用方式:调用Jenkins命令设置job的描述信息。

$JAVA_BIN-jar "$JENKINS_CLI_JAR" -s "$JENKINS_URL"  set-build-description "${JOB_NAME}""${BUILD_NUMBER}" "$tag_name" --username "$SVN_USERNAME" --password"$SVN_PASSWORD"

如果你手头已经搭建了一台Jenkins服务器,那么你也可以访问你的Jenkins,然后通过Jenkins - Manage Jenkins - Jenkins CLI页面查看相关帮助,如下:

<a href="http://i.minus.com/jk81S4rpmGc2n.jpg" target="_blank" class="cboxElement" rel="example4" 2881"="" style="text-decoration: none; color: rgb(1, 150, 227);">

Jenkins的命令行方式:java -jar jenkins-cli.jar [-s JENKINS_URL] command [options...] [arguments...]

<Available Commands>

build:

Builds a job, and optionally waits until its completion.

cancel-quiet-down:

Cancel the effect of the "quiet-down" command.

clear-queue:

Clears the build queue

connect-node:

Reconnect to a node

copy-job:

Copies a job.

create-job:

Creates a new job by reading stdin as a configuration XML file.

delete-builds:

Deletes build record(s).

delete-job:

Deletes a job

delete-node:

Deletes a node

disable-job:

Disables a job

disconnect-node:

Disconnects from a node

dist-fork:

forks a process on a remote machine and connects to its stdin/stdout

enable-job:

Enables a job

get-job:

Dumps the job definition XML to stdout

groovy:

Executes the specified Groovy script.

groovysh:

Runs an interactive groovy shell.

help:

Lists all the available commands.

install-plugin:

Installs a plugin either from a file, an URL, or from update center.

install-tool:

Performs automatic tool installation, and print its location to stdout. Can be only called from inside a build.

keep-build:

Mark the build to keep the build forever.

list-changes:

Dumps the changelog for the specified build(s).

login:

Saves the current credential to allow future commands to run without explicit credential information.

logout:

Deletes the credential stored with the login command.

mail:

Reads stdin and sends that out as an e-mail.

offline-node:

Stop using a node for performing builds temporarily, until the next "online-node" command.

online-node:

Resume using a node for performing builds, to cancel out the earlier "offline-node" command.

quiet-down:

Quiet down Jenkins, in preparation for a restart. Don't start any builds.

reload-configuration:

Discard all the loaded data in memory and reload everything from file system. Useful when you modified config files directly on disk.

restart:

Restart Jenkins

safe-restart:

Safely restart Jenkins

safe-shutdown:

Puts Jenkins into the quiet mode, wait for existing builds to be completed, and then shut down Jenkins.

set-build-description:

Sets the description of a build.

set-build-display-name:

Sets the displayName of a build

set-build-result:

Sets the result of the current build. Works only if invoked from within a build.

shutdown:

Immediately shuts down Jenkins server

update-job:

Updates the job definition XML from stdin. The opposite of the get-job command

version:

Outputs the current version.

wait-node-offline:

Wait for a node to become offline

wait-node-online:

Wait for a node to become online

who-am-i:

Reports your credential and permissions

老李分享:持续集成学好jenkins之内置命令的更多相关文章

  1. 老李分享:持续集成学好jenkins之安装

    老李分享:持续集成学好jenkins之安装   poptest是国内唯一一家培养测试开发工程师的培训机构,以学员能胜任自动化测试,性能测试,测试工具开发等工作为目标.如果对课程感兴趣,请大家咨询qq: ...

  2. 老李分享:持续集成学好jenkins之解答疑问

    老李分享:持续集成学好jenkins之解答疑问   poptest(www.poptest.cn)在培训的过程中使用jenkins搭建持续集成环境,让学员真正交流持续集成到底是什么,怎么去做的. Je ...

  3. 老李分享:持续集成学好jenkins之Git和Maven配置

    老李分享:持续集成学好jenkins之Git和Maven配置   poptest是国内唯一一家培养测试开发工程师的培训机构,以学员能胜任自动化测试,性能测试,测试工具开发等工作为目标.如果对课程感兴趣 ...

  4. 老李分享:持续集成学好jenkins之Git和Maven配置 1

    老李分享:持续集成学好jenkins之Git和Maven配置   poptest是国内唯一一家培养测试开发工程师的培训机构,以学员能胜任自动化测试,性能测试,测试工具开发等工作为目标.如果对课程感兴趣 ...

  5. 老李分享:持续集成学好jenkins

    老李分享:持续集成学好jenkins   poptest是国内唯一一家培养测试开发工程师的培训机构,以学员能胜任自动化测试,性能测试,测试工具开发等工作为目标.poptest测试开发工程师就业培训请大 ...

  6. 老李分享:持续集成学好jenkins之Git和Maven配置 2

    8.检查代码更新并编译 可以通过Poll SCM来设置定时检查编译功能 比如*/5 * * * * 就是每隔5分钟检查一次,如果git仓库中有更新,则执行build操作. 9.使用Maven私服加快下 ...

  7. 研发协同平台持续集成之Jenkins实践

    导读 研发协同平台有两个核心目标,一是提高研发效率 ,二是提高研发质量,要实现这两个核心目标,实现持续集成是关键之一. 什么是持续集成 在<持续集成>一书中,对持续集成的定义如下:持续集成 ...

  8. 使用Gradle构建构建一个Java Web工程及持续集成环境Jenkins配置

    安装Eclipse插件——Buildship 什么是Buildship? Buildship能方便我们通过Eclipse IDE创建和导入Gradle工程,同时还能执行Gradle任务. Eclips ...

  9. Android持续集成之Jenkins 部署

    Android持续集成之Jenkins 部署 [TOC] 0x00安装 准备工作如下: Tomcat8.5下载地址 Jenkins下载链接 1 将下载的jenkins.war包放至tomcat下的we ...

随机推荐

  1. JS作用域理解

    1.JS解析步骤: a.预解析 将变量声明提升: 将函数声明及函数内容提升,可以理解成原来位置的函数在解析代码时已经提到代码初始位置: 遇到重名,只留下一个: 如有重名变量和函数,留下函数: 如有两个 ...

  2. "table" is not mapped 解决方法

    现象:使用hql="from person" 出现" person is not mapped " 错误 配置文件如下:<hibernate-mappin ...

  3. groovy学习(四)io

    package ch5 numbers = [11, 12, 13, 14]def staffTel = ['Ken' : 2745, 'John' : 2746, 'Jessie' : 2772]p ...

  4. 存储过程与SQL语句如何选择

    58到家数据库30条军规,有一条是“禁止使用存储过程.视图.触发器.Event”, 高并发大数据的互联网业务,架构设计思路是“解放数据库CPU,将计算转移到服务层”, 并发量大的情况下,这些功能很可能 ...

  5. Tesseract pytesseract的安装和使用

    Tesseract是开源的OCR引擎,可以识别的图片里的文字,支持unicode(UTF-8)编码,100多种语言,需要下载相应语言的训练数据. 安装: 有两种方法,一种是通过编译源码,比较麻烦.我使 ...

  6. 用VUEJS做一个猫眼电影web app

    之前一直在学习原生js,可是发现原生js虽然很好,但是想实现一个稍微复杂一点的项目都很麻烦.直到遇见了vue.js,发现vue是真的很好用,而且很简洁,利用组件化开发能够快速做出项目,所以为了学习vu ...

  7. debian/ubuntu部署java应用小结

    近期改的Java应用即将部署,为了强强联合,需要把Java应用部署到linux,我们选择了debian系列.小结一下部署的大致过程,如下: Ubuntu已经默认安装了OpenJDK,但还是比较倾向官方 ...

  8. 基于requirejs+bluebird,50行代码实现轻巧实用的前端CMD加载器

    首先是github地址,可以用git克隆命令也可以直接在git页面下载 https://github.com/kazetotori/js-requireAsync 下载下来后目录结构是这样的 -pac ...

  9. File类和时间类的两道综合练习

    练习1: 获取指定目录下(包含子目录)所有的某一种类型的文件 分析: 1.指定路径并获取其下的文件对象 2.要判断给定的目录是否为空 3.要判断给定路径下获取的目录是否为空 4.判断是否是某种文件 5 ...

  10. 用TTL线在CFE环境下拯救半砖wrt54g路由器

    缘起:路由器被刷成半砖 Linksys wrt54gs v4路由器,已刷入 tomato-dualwlan 1.23.使用数年,未出现任何故障. 在日用的wifi网络上,通过web界面刷入了错误的to ...