搭建步骤
廖雪峰老师的搭建git服务器
按照老师上面的步骤一步一步来就可以。
问题
$ git push
Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
问题如上。经过调查,原来是因为git在采用ssh协议传送文件的时候,需要修改一下服务器的配置文件/etc/sshd/sshd_config
PasswordAuthentication yes//默认为yes
必须为yes才可以用。