爱程序网

Linux Apache SVN

来源: 阅读:

yum install mod_dav_svn subversion  httpd

mkdir /var/www/svn
svnadmin create /var/www/svn/puppet
cd /var/www/svn/
chown -R apache.apache puppet
cp puppet/authz ./
htpasswd -c passwd lanxiong
vim authz
[groups]
admin=lanxiong,sawyer
[/]
#[/] 相当于/var/www/svn这个目录,赋予权限给用户组
@admin=rw

httpd subversion.conf
<Location /repos>
    DAV svn
    SVNParentPath /var/www/svn
    AuthType Basic
    AuthName "Authorization SVN"
    AuthzSVNAccessFile "/var/www/svn/authz"
    AuthUserFile "/var/www/svn/passwd"
    Require valid-user
</Location>
httpd restart

[root@ps puppet]# svn ci -m "skdkfads"
Sending        lanxiong
Transmitting file data .
Committed revision 13.

Warning: post-commit hook failed (exit code 1) with output:
svn: E155004: Working copy '/etc/puppetlabs/code/environments/dev/modules/puppet' locked.
svn: E155004: '/etc/puppetlabs/code/environments/dev/modules/puppet' is already locked.
svn: run 'svn cleanup' to remove locks (type 'svn help cleanup' for details)
### 目录改为 chown -R apache.apache  xxx

关于爱程序网 - 联系我们 - 广告服务 - 友情链接 - 网站地图 - 版权声明 - 人才招聘 - 帮助