CVSサーバ構築メモ


CVSサーバ構築メモ

リポジトリを作る

1.リポジトリ用のディレクトリを作成する。

mkdir /home/cvs/cvsroot

2.リポジトリの初期化

cvs -d /home/cvs/cvsroot init

3.リポジトリに登録

CVSROOT=/home/cvs/cvsroot;export CVSROOT
cd /home/cvs/test    ・・・・・ 登録するリポジトリの中に入る。
cvs import -m "comment" test test test_0_1

ポートを空ける

1./etc/services に cvspserverの設定があるか確認する。

2./etc/xinet.d/ 以下に cvspserver ファイルを追加する。

3.pserverの設定

   $ less /etc/xinetd.d/cvspserver
   # default: on
   # description: The wu-ftpd FTP server serves FTP connections. It uses \
   #       normal, unencrypted usernames and passwords for authentication.
   service cvspserver
   {
       protocol                = tcp
       socket_type             = stream
       wait                    = no
       user                    = root
       server                  = /usr/bin/cvs
       server_args             = -f --allow-root=/home/cvsroot pserver
       disable                 = no
   }

4./etc/rc.d/init.d/xinetd restart

5.nmap localhost でポートの確認を行う。

6./etc/hosts.allow, /etc/hosts.deny を編集しアクセス権を与える   (デーモン再起動の必要はなし)

7.DOSにて、

>telnet xxxx 2401

を行い、ログインできるかチェック

8.WinCVSで確認する場合には、CVSROOTに

:pserver:username@hostaddress:CVSROOT_path

を設定し、管理>ログインを行う

コミットメール

CVSROOT/loginfo に記述

ALL (PERL_BADLANG=0; export PERL_BADLANG; /home/cvsroot/CVSROOT/log.pl %s -f 
/home/cvsroot/CVSROOT/commitlog -m syun@moke.co.jp)

PERL_BADLANGは新しいPerlだと ロケールのエラーがでてうざいので消すための応急処置・・・。

自動アップデート

commitされたときに違う場所にあるwwwコンテンツも更新する。

例)

  • モジュール名:html
  • CVSROOT:/home/www/data/CVS
  • webコンテンツ(自動アップを反映させたい場所):/home/www/data/html

★シェルスクリプト /home/www/data/htmlに「update.sh」として以下の内容で作成

#!/bin/sh
touch /home/www/data/test

CVSROOT=/home/www/data/CVS
export CVSROOT
cd /home/www/data/html
cvs update -d &
chmod -R g+w *

★CVSROOT/loginfoに以下の内容を追加

^html /home/www/data/CVS/html/update.sh html

FrontPage

Menu

Linux

サーバ構築

Windows

Java

Program

 

最新の20件

2008-04-02 2008-03-11 2008-01-28 2008-01-21 2007-11-27 2007-09-19 2007-06-07 2007-04-11 2007-04-06 2007-03-22 2006-12-20 2006-12-05 2006-12-04 2006-10-27 2006-09-22 2006-07-03 2006-05-16