better feedback when git-user may not login with ssh public key
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
gitosis (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: gitosis
I was following the instructions in http://
When trying to clone the gitosis-admin repo using
git clone git@YOUR_
(obviously I changed the server hostname, trying localhost, the local IP address as well as the host name).
ns@node0:~$ git clone git@node0:
Initialized empty Git repository in /home/ns/
git@node0's password:
I am using Ubuntu 9.10
Release: 9.10
ns@node0:~$ apt-cache policy gitosis
gitosis:
Installed: 0.2+20080825-15
Candidate: 0.2+20080825-15
Version table:
*** 0.2+20080825-15 0
500 http://
100 /var/lib/
summary: |
- Password request when trying to clone gitosis-admin.git + better feedback when git-user may not login with ssh public key |
I had this problem as well. Git uses SSH for authentication.
Check the output of the following command:
grep "AllowUsers" /etc/ssh/ sshd_config
If "AllowUsers" is present in the SSH daemon config, make sure you include the "git" user.
eg: My "/etc/ssh/ sshd_conf" file contained this line:
AllowUsers vortexcortex
I edited the file via this command:
gksudo gedit /etc/ssh/sshd_conf
Then, I changed the AllowUsers line to read:
AllowUsers vortexcortex git
I saved the file, quit the editor and finally restarted my SSH daemon:
sudo /etc/init.d/ssh restart
(I have also had success via removing the AllowUsers line completely)