Jenkins builds out of the workspace

I am new to Jenkins / Hudson and trying to migrate a C based project from buildbot. For outdated reasons, the build system is hard-coded to build outside the version tree (git), in one directory above, in a separate directory. For instance:.

workspace .git foo bar build artifacts 

In addition to completing the creation of a directory outside the workspace, Jenkins will not recognize elements in the build / directory above to archive as artifacts.

How can I get this build system to work with Hudson? Creating a source tree is not a short-term option. The only option I found is "using a custom workspace", but all this makes it hard code for the workspace directory in another directory.

+6
source share
2 answers

To answer my own question: in Jenkins git, the plugin has an option to check the local subdirectory instead of the root of the workspace. Using the git plugin, click the "Advanced" button and fill in the "Local subdirectory for repo (optional)" field.

+4
source

I cannot find the option mentioned by djs, but you can specify a different working directory:

  • Job Setting
  • Advanced project settings
  • Using custom workspace

It can be installed wherever you want, as well as the workspace of another job.

+3
source

Source: https://habr.com/ru/post/888278/


All Articles