Subversionインストール
yum -y install subversion mod_dav_svn
SVN用リポジトリ作成
mkdir -p /usr/local/svn/repos/xxxxx
svnadmin create /usr/local/svn/repos/xxxxx
svn mkdir file://localhost/usr/local/svn/repos/xxxxx/trunk -m "create"
svn mkdir file://localhost/usr/local/svn/repos/xxxxx/branches -m "create"
svn mkdir file://localhost/usr/local/svn/repos/xxxxx/tags -m "create"
chown -R apache:apache /usr/local/svn/repos
Apache用SVNの設定ファイル編集
vi /etc/httpd/conf.d/subversion.conf
<Location /repos>
DAV svn
SVNParentPath /usr/local/svn/repos
SVNAutoversioning on
Order deny,allow
Deny from all
Allow from 127.0.0.1
Allow from xxxxx
# Require SSL connection for password protection.
# SSLRequireSSL
AuthType Basic
AuthName "Authorization Realm"
AuthUserFile /usr/local/svn/repos/.htpasswd
Require valid-user
AuthzSVNAccessFile /usr/local/svn/repos/.svnaccess
</Location>
Apache用SVNにユーザ認証追加
htpasswd -c /usr/local/svn/repos/.htpasswd 【ユーザ名】
Apache用SVNにユーザ権限設定
vi /usr/local/svn/repos/.svnaccess
[xxxxx:/]
【ユーザ名】 = rw
Apache設定再読込
/etc/rc.d/init.d/httpd reload
ブラウザでhttp://サーバのIP/repos/xxxxx/にアクセス
0 コメント:
コメントを投稿