0

Is it possible to have a .git directory shared between multiple jobs in Jenkins, where each job is using a different branch?

Reason for the question: The repository has 30 GB (all components in one)

Using: Jenkins, Gitlab, one repository has 12-year legacy java app split into services.

  • Hi there! It will be difficult for anyone to provide an accurate answer without having more information. What Source Control Management (SCM) are you using? GitHub? Gitlab? Why is one repository 30 GB? How are you currently using Jenkins with this code? – Argyle Jun 27 at 19:14
  • Hi! Thanks for your answer. I edited the question :) Currently the workspaces are not deleted completly - everything is deleted except ".git", so it does not download everything. I was thinking about an improvement, if ex. git objects could be shared, but current HEAD could be per job. – Krzysztof Wesołowski Jun 28 at 8:48
  • Isn't this just a matter of configuring the trigger branch for the particular pipeline? forum.gitlab.com/t/… seems to describe this – Bruce Becker Aug 3 at 5:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.