I've set up some credentials in Jenkins for bitbucket and double-checked the Credentials settings (e.g. logging in manually) however when I try it in Jenkins it just spins forever giving this output:
> git config remote.origin.url <bitbucket url> # timeout=10 Fetching upstream changes from <bitbucket url> > git --version # timeout=10 using GIT_ASKPASS to set credentials <bitbucket account email> Bitbucket > git fetch --tags --progress <bitbucket url> +refs/heads/*:refs/remotes/origin/* > git fetch --tags --progress <bitbucket url> +refs/heads/*:refs/remotes/origin/*
Note that the URL is fine when public. But when set to Private it simply fails with no output.
Is there anyway to debug this in a bit more detail?
For that purpose, we need to click on the Manage Jenkins option. Step 2: Then, a new tab will open. There we need to click on the Manage Plugin option to add the Credential option there. Step 3: Then we need to click on the Available Tab & we should search for 'Credential' in the search bar provided there.
Git Askpass for Windows (Askpass) provides secure Git credential storage for Windows. Askpass provides multi-factor authentication support for Azure DevOps, Team Foundation Server, and GitHub.
To understand how to configure credentials in a Jenkins environment: Using Credentials. gitToolName. Name of the git installation in the machine running the Jenkins instance (Check Global Tool Configuration section in Jenkins UI)
From the Jenkins home page (i.e. the Dashboard of the Jenkins classic UI), click Manage Jenkins > Manage Credentials. Under Stores scoped to Jenkins on the right, click on Jenkins. Under System, click the Global credentials (unrestricted) link to access this default domain. Click Add Credentials on the left.
I had a similar issue, with Jenkins on a Windows server. I installed git with credentials manager and whenever it tried to checkout a private repository, it would wait for me to input credentials manually in the server. Disabling the git credential manager fixed it for me.
I already had an option to input credentials in the git plugin so didn't need a separate credentials manager.
This is on MacOSX. I changed the Jenkins setting on Git path to /usr/local/git as well as unset the credential.helper using git config, both don't work.
Finally, the problem was resolved by creating a default keychain file for jenkins in ~jenkins/Library/Keychains folder. Herewith is the steps...
After that, the github userid/password is stored in jenkins default keychain and it will be used on jenkins build.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With