Difference between git@github.com:... and https://github.com/...? -
i've attempted building project had various dependencies declared github links. links mixture of links public github repositories , private github enterprise repositories of company.
some of links in format
https://github.com/project/repo.git
and in format
git@github.com:project/repo.git
what difference between such formats , format intended used purpose?
git can operate on variety of different protocols
http(s) https://github.com/project/repo.git
it uses port 443 (or 80 http), allows both read , write access, password auth (like on github allows anonymous read access asks paasword write).and firewall friendly (it not require infra configuration).
ssh git@github.com:project/repo.git
it uses port 22, allows both read , write access, requires ssh keys auth if give git public ssh key, ssh protocol use private key authentication git, not need provide username password.
with ssh not asked provide password each time use git push command ssh protocol use private key authentication repository.
Comments
Post a Comment