Saturday, August 11, 2007

CVS Server How-To

http://www.xfocus.net/articles/200112/314.html

http://greenisland.csie.nctu.edu.tw/wp/2005/06/16/26/

1. Install CVS

2. vi /etc/services
should have these two lines:
cvspserver 2401/tcp # cvs client/server operations
cvspserver 2401/udp # cvs client/server operations

3. Add group and user
> groupadd cvs
> adduser cvsroot
> passwd cvsroot

4. Change permission of /home/cvsroot
> chown cvsroot.cvs /home/cvsroot
> chmod 755 /home/cvsroot

5. xinetd settings
> cd /etc/xinetd.d
> vi cvspserver

service cvspserver
{
disable = no
flags = REUSE
socket_type = stream
wait = no
user = root
server = /usr/bin/cvs
server_args = --allow-root=/home/cvsroot pserver
log_on_failure += USERID
}

6. Initialize CVS repository
> cvs -d /home/cvsroot init

7. Restart xinetd
> /etc/init.d/xinetd restart

8. That's all. Now we can login to CVS.
> cvs -d :pserver:cvsroot@localhost:/home/cvsroot login