关闭

cvs安装配置笔记

标签: cvsserviceuserloginservercommand
670人阅读 评论(0) 收藏 举报
分类:
1 先用源码或rpm包安装cvs
2
# su root
# groupadd cvs
# useradd -g cvs -G cvs –d /home/cvsroot cvsroot
# passwd cvsroot
#chmod –R 775 /home/cvsroot
 
3
# su cvsroot
# cvs -d /home/cvsroot init

4 add xinet service
#su root
vi /etc/xinet.d/cvspserver
service cvspserver
{
        disable = no
        socket_type = stream
        wait = no
        user = root
        env = HOME=
        server = /usr/local/bin/cvs
        server_args = -f --allow-root=/home/cvsroot pserver
}

5 config port
vi /etc/service
cvspserver 2401/tcp #pserver cvs service
cvspserver 2401/udp #pserver cvs service

6 start service
/etc/init.d/xinetd restart
netstat -ln |grep 2401
if result is like this , it's ok.
tcp        0      0 0.0.0.0:2401                0.0.0.0:*                   LISTEN

7 add user and password of cvs
vi passwd.pl
#!/usr/bin/perl
srand (time());
my $randletter = "(int (rand (26)) + (int (rand (1) + .5) % 2 ? 65 : 97))";
my $salt = sprintf ("%c%c", eval $randletter, eval $randletter);
my $plaintext = shift;
my $crypttext = crypt ($plaintext, $salt);
print "${crypttext}";

vi /home/cvsroot/CVSROOT/passwd
user1:xxxxx:cvsroot
user2:xxxxx:cvsroot
user3:xxxxx:cvsroot

xxxxx is the result of
"./passwd.pl xxxxxxx"


8 login and add project to resposity
#su user1
vi .bash_profile
//add this line:
export CVSROOT=:pserver:user1@localhost:2401/home/cvsroot

#cvs login   // input the passwd after this command
// if my project code is under /project_src
#cvs import -m "some message about this project" /project_src v_0_0_1 start

ok, that's all.
0
0

查看评论
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
    个人资料
    • 访问:15281次
    • 积分:301
    • 等级:
    • 排名:千里之外
    • 原创:13篇
    • 转载:1篇
    • 译文:0篇
    • 评论:0条
    文章分类