Setting Up CVS on the Server


Now that you know the basics of using CVS, the server administration can be discussed.

Assuming you are running a newer 2.4.x Linux kernel, your system used xinetd instead of inetd for configuring network services. Make sure you already have the CVS client program installed and in your PATH. There should be a directory which stores all xinetd configuration files, /etc/xinetd.d by default.

 cd /etc/xinetd.d 

Touch a file called cvspserver, and use a command line editor, such as vi to edit the file.

Now, insert the following text into the cvspserver file:

 service cvspserver {    port        = 2401    socket_type = stream    protocol    = tcp    wait        = no    user        = root    passenv     = PATH    server      = /usr/ bin/cvs    server_args = -f --allow-root=/usr/local/cvsroot pserver } 

Make sure the server attribute corresponds to the location of the cvs executable on your server. If you dont know this value, type which cvs to discover the binary executable.

Once this configuration file has been created, xinetd needs to be told to reload its configuration files. This is usually done by asking xinetd to restart. Issue the following command:

 /etc/init.d/xinetd restart 

You should see the process stop and start. You are now ready to use the cvs server. CVS must be told to init the new server repository. Choose the location where you would like to keep the CVS repository, and issue the following command as root. Make sure this matches the allow-root part of the server_args line in your cvspserver file. Its once again easiest to set CVSROOT in the environment.

 cvs init 

The cvs command has now set up a repository. Change directory to $CVSROOT and create a directory called projosdev, users can now access this module on the cvs server. It is important that users accessing the repository have write access to this directory. Create a group called cvsusers, and give that group write access to the $CVSROOT directory.

Unlike other services that use daemons, there is no cvsd; rather, the cvs client program actually acts as the server. Therefore no entries to the startup scripts are needed.




Professional Java Tools for Extreme Programming
Professional Java Tools for Extreme Programming: Ant, XDoclet, JUnit, Cactus, and Maven (Programmer to Programmer)
ISBN: 0764556177
EAN: 2147483647
Year: 2003
Pages: 228

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net