Reputation: 841
I've been trying to pull down a repository from Gitlab using SSH keys. All done in command line on Windows 8 via a Ubuntu VM. I've added my public key to my Gitlab account and then added my private key to the ssh-agent and didn't seem to have any errors in doing so but when I try and do a git pull or push I run in to this error;
fatal: unable to access 'https://git.mgmt.local/XXX/project-name.git/':
server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none
And that's run me straight in to a wall ... no idea on what's wrong, can anyone point me in the right direction?
Upvotes: 1
Views: 7167
Reputation: 1324278
That is because you are using an https url.
Https means the public and private ssh keys stored in %HOME%.ssh are not used. At all.
Try switching to an ssh url:
git remote set-url origin (user)@(ip address):(group)/(project).git
With a standard GitLab installation (user)
should be git
.
You can check first if ssh is working with:
ssh -Tvvv git@your_server.com
Upvotes: 3