Hello!
Recently I updated my Jenkins installation including all of the plugins. One of them must have brought somewhat breaking changes because when I tried to create a new build configuration for a new old project of mine, I could not select the proper credentials in the dropdown. I only had the option to add new ones even though I had added the corresponding credentials in the global scope (as per usual), so they must have been visible across the entire Jenkins instance. None of them were showing up. And even when I tried adding new ones through the build configuration page, they ended up not being active / selected either.
When I went back to check with an existing build configuration I had configured over a year before, I could confirm the same behavior. For build parameters the credentials dropdowns were empty and for the VCS credentials it said
Cannot find any credentials with id <ID>
I spent a couple of hours looking for solutions and I did find some cases that popped up around 1 or 2 years ago, but nothing that fit this exact scenario. My suspicion was that this might be a bug, so I tried rolling back the SSH credentials and credentials plugins to the previous versions, but that did not fix anything.
I decided to wait for a week in the hopes of potential bug fix releases to come out for either some of the plugins or Jenkins itself, but a week later in spite of a couple of updates here and there, nothing about the problem had changed.
And then I found a comment in the discussion thread of a GitHub issue of the "GitHub Pull Request Builder Plugin" (which I am not even using). In it, the following solution was proposed:
- Navigate to "Jenkins" (main menu) => "Manage Jenkins" => "Configure Global Security"
- Go to the "Access Controls for Builds" section
- Under "Project default Build Authorization" check if the "Strategy" is set to "Run as anonymous" (which was the case for me)
- If yes, try changing it to "Run as User who Triggered Build" (it might also work with another setting if that suits you better)
- Save and reload the build configuration settings
That was it! The credentials showed up again and I could execute the build successfully.
I know this seems to be a niche problem and there might only be a handful of people that have encountered the same issue, but I hope it was helpful nonetheless.
Thank you for reading!
Like this:
Like Loading...
Hi!
If you have installed msysgit and are planning on using it in combination with Pageant from the PuTTY tool suite, you might run into the problem that it does not attempt to use any of the keys you have already loaded into Pageant. You can fix this by telling msysgit which program to use for the git fetch and pull operations:
- Open your System window (Windows + Pause or "Start" => Right-click on "Computer" => "Properties")
- Click on "Advanced system settings" (on the left)
- Click on "Environment Variables..." (on the bottom)
- Add a new system variable (or user variable if you just want this setting for the current user): "New..."
- Variable name: GIT_SSH
Variable value: (path to plink.exe) for example: C:\Program Files (x86)\PuTTY\plink.exe (important: just the path, no quotation marks at the beginning or the end!)
- If you haven't already on this system / user, connect to the server via PuTTY in order to get the SSH server fingerprint prompt and remember it
- Close any existing Git Bash / msysgit instances and start it up again
This should do it!
I hope this was helpful.
Thanks for reading!
Source: http://www.bitsandpix.com/entry/git-setup-msysgit-install-with-pageantplink-from-putty/
Like this:
Like Loading...