We are having an issue where one user is getting an error when trying to commit with a valid JIRA issue. The JQL we have setup is project in myProjects(). This works for all users who have tested it except for one. The user who is having the issue is an administrator of the JIRA project, and the JIRA issue number is valid as other users are not having the same issue with the same JIRA issue number.
We are unable to see anything in the logs other than the commit is rejected.
So the issue is the user is using SSH keys to make the connection, and the SSH key is setup with his email address and not his JIRA ID.
If he creates a new SSH key with his JIRA ID will it work, or does this hook only work when committing with HTTPS.
This should work regardless of using SSH or HTTPS, as long as it's setup correctly. Are any other users using SSH with this hook?
You may want to check the repository contains the correct remote base url by running:
git remote -v
It should look similar to the ones here.
Yes we have other users that are using SSH there. He also just tried to switch to HTTPS and had the same issue with the hook. Below is log output.
https | o@1O3A096x556x4729749x0 | E731TK | 2017-02-23 09:16:36,919 | "GET /scm/rcs/rental-clients-training.git/info/refs HTTP/1.1" | "" "git/2.10.1" | 200 | 0 | 865 | refs | 433 | - |
https | o@1O3A096x556x4729751x0 | E731TK | 2017-02-23 09:16:38,179 | "POST /scm/rcs/rental-clients-training.git/git-upload-pack HTTP/1.1" | "" "git/2.10.1" | 200 | 341 | 178025 | cache:miss, clone | 909 | - |
https | o@1O3A096x559x4730353x1 | E731TK | 2017-02-23 09:19:05,598 | "GET /scm/rcs/rental-clients-training.git/info/refs HTTP/1.1" | "" "git/2.10.1" | 200 | 0 | 735 | refs | 394 | - |
https | o@1O3A096x559x4730355x1 | E731TK | 2017-02-23 09:19:08,078 | "POST /scm/rcs/rental-clients-training.git/git-receive-pack HTTP/1.1" | "" "git/2.10.1" | 200 | 495 | 366 | push, rejected | 2094 | - |
He also has no issues making commits when the require JIRA commits hook is disabled. I will check if other users on his team are using SSH but I believe others are without issues. Is there a way to enable more logging for that hook so it will output more information?
I haven't found much. Could you get the user to reset their credentials, in particular the credentials cache for that repository. Maybe they are wrong. There are some instructions here for doing this in Git here: http://stackoverflow.com/questions/18157583/git-credential-helper-cache-never-forgets-the-password
Can you get the user to run the same JQL query in the JIRA advanced search? What comes back? Also does this user have the same details like username etc in Bitbucket and JIRA?
It sounds like there is something specific about this user that is causing this problem.
As a project manager, I have discovered that different developers want to bring their previous branching method with them when they join the team. Some developers are used to performing individual wo...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs