Jenkins is no more works with reference git repository

Jenkins is no more works with reference git repository. Reference repository is introduced to reduced direct connection to the remote Git server (in our case, Gerrit), However Jenkins still fetching the data from the remote repository post setting up remote repository config.

Steps done:

  1. Added git plugin
  2. Provided repository url and credential in the configure page of Jenkins
  3. Selected, ‘Advanced clone behaviours’ from ‘advanced Behaviors’
  4. Provided path where the bare git repository located. (bare repo created by cloning gerrit with --mirror option)
  5. Triggered the build

Note : Tried deleting the job from /var/lib/jenkins/workspace, but still using remote repo for cloning.

Hello @jy_jenkins and welcome to this community :wave:

What is the version of Jenkins you’re running?
On which OS?
With which version of Java? From which vendor?
What is the git plugin version you’re using?

Thanks.

Hi Bruno Verachten,

Thank you for your reply.
I have added the requested details below,

What is the version of Jenkins you’re running?
2.375.2

On which OS?
Red Hat Enterprise Linux Server 7.9 (Maipo)

With which version of Java? From which vendor?
openjdk version “11.0.17” 2022-10-18 LTS, java.vm.vendor = Red Hat, Inc.

What is the git plugin version you’re using?
Git plugin
Version5.0.0

1 Like

Could possibly be caused by the CVE-2022-24765 fix in Git 2.30.3, if Jenkins runs as a user different from the owner of the repository. See safe.directory.

1 Like