I am trying to set up a Jenkins Windows slave which will pull from GitHub using Git Bash. I have installed Git Bash on my Windows server so it is available through the Windows command prompt. When I try to invoke any Git command that goes to GitHub it always asks for my credentials.
How can I set this up so it does not ask for my credentials?
Points to note:
I am testing it by invoking from the Windows cmd and not the Git Bash shell as I believe this is how Jenkins will call it.
If it isn't possible, how do you connect to GitHub from a Jenkins slave via Git Bash without it asking for credentials?
-
You need to install ssh key for Jenkins See stackoverflow.com/questions/15314760/…Vitalii Velikodnyi– Vitalii Velikodnyi2015年04月30日 10:49:19 +00:00Commented Apr 30, 2015 at 10:49
-
This solution is for linux. I will be hitting github from a windows command promptuser1107753– user11077532015年04月30日 11:06:00 +00:00Commented Apr 30, 2015 at 11:06
2 Answers 2
I had a browse around and managed to find my answer. It is solved by the following post
Is there a way to skip password typing when using https:// on GitHub?
Works a treat!!
Comments
See Git Bash at https://msysgit.github.io
It's a Linux-like console for Windows.
You will need to generate SSH keys which will be in your HOME_DIR/.ssh folder.
As an example, see Working with Git on Windows .
After generating keys, install it to the GitHub account.