# project: set up cvs server

## numerodix

I've been struggling trying to set up a cvs server all day and I'm stuck. The steps so far...

1. emerge cvs

2. config /etd/xinetd.d/cvspserver

3. Add user cvspserver and group cvsusers to execute the server, as defined in the file above

4. emerge xinetd, add to default runway, remove only_from= argument in /etc/xinetd.conf 

5. Set up firewall for port 2401

6. Define a repository

#cvs -d /cvs/project init

7. Added to .bash_profile:

CVSROOT=/cvs/project 

export CVSROOT

(as instructed in http://www.cvshome.org/docs/manual/cvs_2.html#SEC10 )

8. Tried checking out a file locally..

#cvs -d /cvs/project checkout CVSROOT/modules

M CVSROOT/project 

Ok, it works

9. Tried commiting a file locally, root cannot commit

#cvs -d /cvs/project commit modules

cvs [commit aborted]: 'root' is not allowed to commit files

10. Added project files

#cvs import -m "Imported sources" project_name vendor_name start

(as instructed in http://www.cvshome.org/docs/manual/cvs_3.html#SEC40 )

11. Added user cvs, tried commiting with new user

User has this entry in /etc/passwd:

cvs:x:1053:407:CVS owner:/home/cvs/:/bin/bash

12. Configure CVSROOT/passwd with correspondig cvsuser system user (as described in http://www.cvshome.org/docs/manual/cvs_2.html#SEC29 )

user::cvs

first string is user for cvs server, second is password, last is system user commands are actually run as

13. Tried to connect with 

# cvs -d :pserver:user@hostname:2401/cvs/project login

Logging in to :pserver:user@hostname:2401/cvs/project 

CVS password:

/cvs/project: no such repository

???

/etc/xinetd.d/cvspserver

 *Quote:*   

> 
> 
> service cvspserver
> 
> {
> ...

 

So basically I can't connect to the server externally, even though the repository is specified in the command line.

Sources used:

http://www.gentoo.org/doc/en/cvs-tutorial.xml

http://www.cvshome.org/docs/manual/cvs.html

https://forums.gentoo.org/viewtopic.php?t=38844&highlight=cvs (fix problem with user not being able to run /usr/bin/cvs)

https://forums.gentoo.org/viewtopic.php?t=36628&highlight=cvs (set up user and group to run the server)

----------

## DuF

Maybe there is a problem with the home of the cvs user (/home/cvs) and the chrooted path (/cvs/projet).

If you try without chroot in the /etc/xinetd.conf, have you the same result ?

----------

## pedro

Anyone knows how to authenticate CVS against PAM?

I'm trying to install the cvs-nserver, but it seens not to work.

I need PAM to use my WINNT logins.

thanks

----------

## Plaz

I also recommend getting it up and running first without using chroot.  For one thing, the xinetd config file you posted didn't seem to include the chroot target directory in the server_args list.  Setting up to run in a chroot jail takes a bit of work if you haven't done it before.

I run a chrooted CVS server, but I run a cvsd process instead of running cvs through xinetd.  If you can get it working with cvsd, I suppose the conversion to xinetd should be fairly simple.  I can post my config files, but it might be easier if I can send you a sample .tgz file or something since there are several files/directories involved.

----------

## S_aIN_t

 *pedro wrote:*   

> Anyone knows how to authenticate CVS against PAM?
> 
> I'm trying to install the cvs-nserver, but it seens not to work.
> 
> I need PAM to use my WINNT logins.
> ...

 

you can set up the cvs server to use the same logins as your WINNT logins by putting the user:passwd entries into the $CVSROOT/passwd file.

----------

