Git does not have an inbuilt ssh server. Git assumes that
- the
git
client can use the ssh
binary to initiate an ssh connection
- the
git
server (at least on Unix) can be invoked as a command run from the ssh
server.
You are probably familiar with the syntax
ssh foo.bar baz
which runs baz
on foo.bar
. The git client uses a similar configuration to run the ssh
server which in turn runs the server-side git binary (the same binary as the client but run with different flags). Normally you would have a git
user to do this. You can do this without any programs other than ssh
and git
(see first answer here) but you may find installing gitolite
makes things easier (in essence your git server config is also stored in a git
repo, so you don't have to do any server side maintenance by logging in).