How to get a Job / Folder directory ?

Issue

  • How do I get a Jenkins Item (Pipeline Job, Folder, Multibranch Job, Freestyle Job, etc…) directory ?
  • Diagnosing Jenkins Item issues

Resolution

The directory of an Item contains most of the information needed to diagnose Item issues. There are different ways to collect it.

From the UI

If using Support Core 2.67 or later, you can download directly from the UI. Navigate to the Item page and click on the Support link. Then click on Generate Bundle:

Note: you may adjust the options to collect specific data. For more details about the different options, have a look at the help ? tooltips.

With cbsupport

With the cbsupport CLI, you can download an item directory by using the command cbsupport required-data item. See 2.5.2. Generating information for a Jenkins Job / Folder issue for more details.

From the File System

In any case, you can find the item directory of a specific item in the file system under the Item Root Directory at $JENKINS_HOME/jobs/$PATH_TO_JOB/.

Note: you may exclude the underlying stashes/, jobs/ and builds/ directories or cherry pick what you are looking for to avoid collecting too much data

References

Have more questions?

0 Comments

Please sign in to leave a comment.