一、安装Subversion

#yum install subversion
 
1.查看安装时的文件产生情况,使用 rpm -ql subversion
2.卸载subversion:#yum remove subversion
3.停止subversion服务:#killall svnserve
 
二、创建仓库(以创建多个仓库为例)
#svnadmin create /var/svn/demo
#svnadmin create /var/svn/coffeetest
/var/svn/demo和/var/svn/coffeetest为所创建仓库的路径,理论上可以是任何目录。这里我取/var/svn为所有仓库的总路径,在目录下面分别创建仓库。
 
三、配置仓库
针对每个仓库单独配置,分别修改每个仓库conf目录下面的三个配置文件(authz、passwd、svnserve.conf)
 
1.修改authz文件,这个配置文件里面可以设置用户组和用户目录权限
==============================
[groups]
# harry_and_sally = harry,sally
# harry_sally_and_joe = harry,sally,&joe
admin = admin,user1,user2
 
# [/foo/bar]
# harry = rw
# &joe = r
# * =
 
[/]
@admin = rw
*      =
==============================
上面绿色部分是我配置的内容,第一行绿色的是配置一个用户组admin 有成员admin和novalue两个;第二行绿色的开始配置目录权限,设置admin组(前面加@符号)的权限为读写权限,其他成员没有权限(* = )
 
2.修改passwd文件,设置访问当前仓库的用户和密码
===========================================
[users]
# harry = harryssecret
# sally = sallyssecret
admin  = 123456
user1  = 123456
user2  = 123456
===========================================
 
3.修改svnserve.conf文件,开启权限控制等功能
找到第一个常规选项[general],把前面是一个#号的去掉#号,如下是我的demo仓库配置内容
===========================================================================
[general]
### These options control access to the repository for unauthenticated
### and authenticated users.  Valid values are "write", "read",
### and "none".  The sample settings below are the defaults.
anon-access = none
auth-access = write
### The password-db option controls the location of the password
### database file.  Unless you specify a path starting with a /,
### the file's location is relative to the directory containing
### this configuration file.
### If SASL is enabled (see below), this file will NOT be used.
### Uncomment the line below to use the default password file.
password-db = passwd
### The authz-db option controls the location of the authorization
### rules for path-based access control.  Unless you specify a path
### starting with a /, the file's location is relative to the the
### directory containing this file.  If you don't specify an
### authz-db, no path-based access control is done.
### Uncomment the line below to use the default authorization file.
authz-db = authz
### This option specifies the authentication realm of the repository.
### If two repositories have the same authentication realm, they should
### have the same password database, and vice versa.  The default realm
### is repository's uuid.
realm = coffeetest svndata
==========================================================================
注意:所有的行都必须顶格,否则报错。
 
四、启动和关闭服务
1.启动服务
#svnserve -d -r /var/svn --listen-host 192.168.1.16
 
命令中/var/svn是我所有仓库的所在的根目录,如果单个仓库,可以直接写仓库地址即可,比如启动demo仓库,#svnserve -d -r /var/svn/demo --listen-host 192.168.1.16
 
2.停止服务
#killall svnserve
 
五、访问仓库项目
我们有两个代码仓库/var/svn/demo 和/var/svn/test,那么在客户端访问时可以用
svn://192.168.1.16/demo

[转载]centos安装svn服务器的更多相关文章

  1. CentOS安装SVN服务器

    Step1:安装svn服务器 $ yum install subversion Step2:创建SVN版本库目录 $ mkdir /workplace/svnrepos Step3:创建版本库 $ s ...

  2. Centos 7中安装svn服务器,史上最详细

    最近上头安排了帮客户安装svn服务器,用了两种方式安装,yum命令安装,快速简洁容易上手,但是源码安装就比较繁琐,两种方式都试了一下,yum命令基本一个多小时就安装完了,但是源码安装弄了我两天的时间, ...

  3. CentOS 6.5系统上安装SVN服务器

    有效地管理源代码的方式是使用工具去帮助我们管理 , SVN(Subversion)就是目前主流的源代码管理工具 , 也称为版本控制工具. 本文主要介绍CentOS6.5上安装SVN服务器,配置SVN服 ...

  4. CentOS 创建SVN 服务器,并且自动同步到WEB 目录

    CentOS 创建SVN 服务器,并且自动同步到WEB 目录 标签: centossvnsubversion服务器 2013-12-06 10:09 5492人阅读 评论(0) 收藏 举报  分类: ...

  5. [记录]CentOS搭建SVN服务器(主从同步)

    CentOS搭建SVN服务器(主从同步)1.安装步骤如下: 1)安装: #yum install subversion 2)查看安装位置: #rpm -ql subversion 3)查看版本: #/ ...

  6. CentOS搭建SVN服务器,并通过Apache HTTP方式访问

    摘要:本文主要讲述了在centos 6.5环境下搭建svn服务器,可通过svn:\\IP方式访问.同时由于部分公司内网端口限制,并不能访问外网的svn服务器,所以特地结合了apache服务器,使得可以 ...

  7. Centos 安装SVN

    Centos 安装SVN  centos(我这里使用的是CentOS7)下yum命令即可方便的完成安装 $ sudo yum install subversion 测试安装是否成功: $ svnser ...

  8. CentOS 搭建 SVN 服务器 及使用教程

    服务器与客户端 1.搭建SVN服务器 ① CentOS安装SVN 命令: yum -y install subversion 检查是否安装成功 命令: svn --version 如果显示如下内容说明 ...

  9. centos搭建svn服务器

    1.在centos6.5上面搭建svn服务器,安装svn服务器:yum install subversion 2.在任意目录下创建仓库目录,这里放在/data/mypros目录下 3.执行命令:svn ...

随机推荐

  1. BCB中实现拖拽Panel 改变位置和大小的代码

    //--------------------------------------------------------------------------- #ifndef Unit1H #define ...

  2. 多层iframe的页面取子标签

    <iframe src=''> <iframe src=''> <iframe src=''> <div></div></iframe ...

  3. 打造一个有感觉的vim(四)

    今天要介绍的VIM插件的名字叫做surround,这个插件的主要作用是将一个VIM的tex-objects(文本对象)添加或者取消包裹(单引号,双引号,XML标签等等)下载地址如下:https://g ...

  4. seaJS循环依赖的解决原理

    seajs模块的六个状态. var STATUS = {  'FETCHING': 1, // The module file is fetching now. 模块正在下载中  'FETCHED': ...

  5. Win7与Mint双系统安装体验

    双系统安装前的准备 1.安装前的准备 安装双系统可能会对磁盘文件带来一些影响,为了避免在安装过程中由于系统瘫痪造成不必要的损失,所以我们在准备安装双系统之前,要对PC机中的重要文件进行备份,对资料要做 ...

  6. nullcon HackIM 2016 -- Crypto Question 1

    You are in this GAME. A critical mission, and you are surrounded by the beauties, ready to shed thei ...

  7. Android Studio新建一个HelloWorld 程序(App)

    Android Studio新建一个HelloWorld程序(App) 新建 或者直接启动程序(注:如果已有程序,此方法会直接打开最近一次关闭从程序) 更改App名 选择App运行平台 选择模板 更改 ...

  8. lua 代码风格

    参考  http://www.kancloud.cn/kancloud/lua_style_guide/66327 1.命名 1.命名法:小驼峰命名法,大驼峰命名法(Pascal命名法),小下划线命名 ...

  9. 我的新博客:www.wangyufeng.org

    新博客:www.wangyufeng.org 博客园的博客不更新啦.

  10. Activity启动模式

    ------siwuxie095 共4种启动模式:standard singleTop singleTask singleInstance 1.标准启动模式(standard) 也即默认的启动模式 ( ...