在本地文件上执行jenkins构建 [英] Perform jenkins build on local files

查看:833
本文介绍了在本地文件上执行jenkins构建的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有一台Jenkins服务器,我已经在其中定义了我的工作.它使用Perforce作为SCM.

We have a Jenkins server where I have already defined my job. It uses Perforce as SCM.

我想复制Jenkins用来构建项目的所有步骤,但是要使用本地工作区中的文件.基本上,我想基于另一台服务器上定义的作业在本地运行jenkins构建.

I would like to replicate all the steps that Jenkins takes to build the project but use the files in my local workspace instead. Basically, I would like to run a jenkins build locally based on a job defined on another server.

我该怎么做?

推荐答案

类似为我的Perforce用户创建的内容可能对您有用-我在Jenkins中添加了一项工作,可以抓取搁置的文件(因此,用户需要以保存文件),从那里创建一个版本,然后让用户知道它是否成功(他们还可以选择运行测试或创建可部署的版本).要点是请求搁置的变更列表#,然后执行此操作:"p4搁置-s%SHELVEDCL%"并照常进行.他们在喜欢的时候就使用它.这很有用.但这确实需要访问詹金斯.

Something like what I created for my Perforce users might work for you -- I added a job in Jenkins that will grab shelved files (so, the user would need to shelve the files), create a build from there, then let the user know if it was successful (they also have the option of running tests or creating a deployable build). The gist of it is to request the shelved changelist #, then do this: "p4 unshelve -s %SHELVEDCL% " and proceed as usual. They use it when they feel like it; it's been useful. But it does require access to Jenkins.

这篇关于在本地文件上执行jenkins构建的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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