我如何在 Jenkins 中克隆一份工作? [英] How do I clone a job in Jenkins?

查看:28
本文介绍了我如何在 Jenkins 中克隆一份工作?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

JenkinsGerrit 插件,所以当我们签入 Gerrit 时,Jenkins执行构建,如果成功,则验证 Gerrit 中的修改.如果构建失败,则不是.我的理解是,这是通过在 Jenkins 中设置的作业来完成的.我们现在已经创建了一个新分支 (git),我想我需要克隆指向另一个分支的现有作业,以便发生相同的工作流并在每次提交时执行构建.有人可以解释我将如何克隆这些工作吗?我似乎没有看到通过 UI 执行此操作的方法,甚至也没有看到通过 UI 列出作业的方法.

Jenkins has the Gerrit Plugin in place so that when we do check-ins to Gerrit, Jenkins performs a build and if it succeeds, then the modification in Gerrit is verified. If the build fails then it is not. My understanding is that this is accomplished through jobs set up in Jenkins. We have now created a new branch (git) and I guess I need to clone the existing jobs pointing to the other branch so that this same workflow occurs and builds are performed on every commit. Can somebody explain how I would clone these jobs? I don't seem to see a way to do it through the UI nor can I even see a way to list the jobs out through the UI.

推荐答案

要复制现有作业,请转到 http://your-jenkins/newJob 并使用复制现有作业"选项.输入现有作业的名称 - Jenkins 会验证它是否存在.

To copy an existing job, go to http://your-jenkins/newJob and use the "Copy existing job" option. Enter the name of the existing job - Jenkins will verify whether it exists.

Jenkins首页的默认选项卡应该列出所有现有的工作,但可能你的前任删除了该选项卡.您可以创建一个新标签,列出来自 http://your-jenkins/newView.

The default tab on the front page of Jenkins should list all existing jobs, but maybe your predecessor deleted the tab. You can create a new tab listing all jobs from http://your-jenkins/newView.

这篇关于我如何在 Jenkins 中克隆一份工作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆