When you create a new project in GitLab, it shows a message:
You won’t be able to pull or push project code via SSH until you add an SSH key to your profile.
There are a few pages on GitLab that explains how you can generate SSH Key but none of them ever say why you should use it in the first place.
- Why shouldn’t I prefer HTTPS over SSH?
- What are the differences between the two?
This question further illustrates the lack of good documentation, I am yet to get an answer to any of my GitLab’s related questions on GitLab itself. GitLab hasn’t addressed this question but GitHub has. They recommend HTTPS.
I would appreciate if someone could explain why SSH is preferred on GitLab and why not to use HTTPS.