GIT Server install failing on Ubuntu

2019-08-07 04:02发布

I'm trying to install my own git server with these instructions.

http://cisight.com/how-to-setup-git-server-using-gitolite-in-ubuntu-11-10-oneiric/

But I am get stuck at this point.

git clone --verbose  gitolite@ec2-xxx.compute-1.amazonaws.com:testing.git
Cloning into 'testing'...
Permission denied (publickey).
fatal: The remote end hung up unexpectedly

And I think it has something to do with this:

gitolite@ip-xxxx:~$ gl-setup tmp/john.pub 

key_read: uudecode Aklkdfgkldkgldkgldkgfdlkgldkgdlfkgldkgldkgdlkgkfdnknbkdnbkdnbkdnbkfnbkdfnbkdnfbkdfnbdknbkdnbkfnbkdbnkdbnkdfnbkd john@example.com
 failed
fprint failed

I always get the fail and I think its preventing me from cloning repo.The repo is there along with gitolite-admin.git repo. The permissions are this:

drwxr-x--- 8 gitolite gitolite 4096 Jun  6 16:29 gitolite-admin.git
drwxr-x--- 7 gitolite gitolite 4096 Jun  6 16:29 testing.git

So my question is what am I missing here?

1条回答
Summer. ? 凉城
2楼-- · 2019-08-07 04:42

This thread reports:

acting on a hunch I removed the IP address of my git repo from my known hosts. The error immediately went away.

If you’re getting the same message, determine the IP address or domain name of your git repo.
Search for those values in your ~/.ssh/known_hosts file and remove them. You should be good to go after that.

It can be that, or you don't have generated your ssh key properly somehow.

ssh-keygen -t rsa -f "${HOME}/.ssh/gitoliteadm" -C "Gitolite Admin access (not interactive)" -q -P ""
查看更多
登录 后发表回答