1. install git, git-daemon, xinetd
>yum install git git-daemon xientd
2. edit /etc/xinetd.d/git file
disabled = no
3. open port 9418 in firewall
4. the git repositories in /var/lib/git directory
5. create a repository in /var/lib/git
>mkdir test
>cd test
>git init --bare --shared
5. restart xinetd
>service xinetd restart
6. try to clone test repository from remote
>git clone git://[server_ip]/test
or with ssh ( can push ):
>git clone root@[server_ip]:/var/lib/git/test
Reference:
http://blog.longwin.com.tw/2011/03/build-git-env-share-over-ssh-2011/
沒有留言:
張貼留言