I\'m creating a job in Jenkins 2.152 running on Windows Server 2016 which needs to pull from a git repo hosted on bitbucket.org. I tested the ssh key through git-bash so I k
following worked for me
Create a folder (say testkey), cd inside the folder and right click and select git bash
now create OPENSSH Key using following command in git bash. here test.key is name of your OPENSSH key (note that passphrase is optional)
ssh-keygen -f test.key
ssh-keygen -f test-pem.key -m PEM -p
Now the key is converted into PEM key, copy the content of the key using notepad.
Go Jenkins -> Credentials -> Add New Credentials.
7.Select Kind SSH Username and Key , Provide username , and paste the PEM key content copied in step 5 and paste into private key, note that passphrase is optional.
Original SSL Command Copied from GITHUB - git@github.com:test/goto.git
change it to - ssh://git@github.com/test/goto.git