名称

mod_dav_svn 配置指令 — 通过 Apache HTTP 服务器提供 Subversion 版本库服务的配置说明。

描述

This section briefly describes each Subversion Apache configuration directive. For an in-depth description of configuring Apache with Subversion, see 第 4 节 “httpd - Apache 的 HTTP 服务器”.

指令

These are the httpd.conf directives that apply to mod_dav_svn:

DAV svn

Must be included in any Directory or Location block for a Subversion repository. It tells httpd to use the Subversion backend for mod_dav to handle all requests.

SVNActivitiesDB directory-path

Specifies the location in the filesystem where the activities database should be stored. By default, mod_dav_svn creates and uses a directory in the repository called dav/activities.d. The path specified with this option must be an absolute path.

If specified for an SVNParentPath area, mod_dav_svn appends the basename of the repository to the path specified here. For example:

<Location /svn>
  DAV svn

  # any "/svn/foo" URL will map to a repository in 
  # /net/svn.nfs/repositories/foo
  SVNParentPath         "/net/svn.nfs/repositories"

  # any "/svn/foo" URL will map to an activities db in
  #  /var/db/svn/activities/foo
  SVNActivitiesDB       "/var/db/svn/activities"
</Location>
SVNAllowBulkUpdates On|Off

Toggles support for all-inclusive responses to update-style REPORT requests. Subversion clients use REPORT requests to get information about directory tree checkouts and updates from mod_dav_svn. They can ask the server to send that information in one of two ways: with the entirety of the tree's information in one massive response, or with a skelta (a skeletal representation of a tree delta) which contains just enough information for the client to know what additional data to request from the server. When this directive is included with a value of Off, mod_dav_svn will only ever respond to these REPORT requests with skelta responses, regardless of the type of responses requested by the client.

Most folks won't need to use this directive at all. It primarily exists for administrators who wish—for security or auditing reasons—to force Subversion clients to fetch individually all the files and directories needed for updates and checkouts, thus leaving an audit trail of GET and PROPFIND requests in Apache's logs. The default value of this directive is On.

SVNAutoversioning On|Off

When its value is On, allows write requests from WebDAV clients to result in automatic commits. A generic log message is auto-generated and attached to each revision. If you enable autoversioning, you'll likely want to set ModMimeUsePathInfo On so that mod_mime can set svn:mime-type to the correct MIME type automatically (as best as mod_mime is able to, of course). For more information, see 附录 C, WebDAV 和自动版本. The default value of this directive is Off.

SVNIndexXSLT directory-path

目录列表所使用的 XSL 的 URI。这个指示可选。

SVNListParentPath On|Off

When set to On, allows a GET of SVNParentPath, which results in a listing of all repositories under that path. The default setting is Off.

SVNMasterURI url

Specifies a URI to the master Subversion repository (used for a write-through proxy).

SVNParentPath directory-path

指定目录是 Subversion 版本库的父目录在文件系统的位置。在一个 Subversion 版本库配置块里,必须提供这个指示或 SVNPath,但不能同时存在。

SVNPath directory-path

这个指示指定 Subversion 版本库文件在文件系统中的位置。在一个 Subversion 版本库的配置块里,必须提供这个指示或 SVNParentPath,但不能同时存在。

SVNPathAuthz On|Off|short_circuit

Controls path-based authorization by enabling subrequests (On), disabling subrequests (Off; see 第 4.4.3 节 “禁用基于路径的检查”), or querying mod_authz_svn directly (short_circuit). The default value of this directive is On.

SVNReposName name

指定 Subversion 版本库在 HTTP GET 请求中使用的名字。这个值会作为所有目录列表(当你用浏览器察看 Subversion 版本库时会看到)的标题。这个指示是可选的。

SVNSpecialURI component

指定特定 Subversion 资源的 URI 组件(命名空间)。默认是 !svn,大多数管理员不会用到这个指示。只有那些必须要在版本库中放一个名字为 !svn 的文件时需要设置。如果你在一个已经使用中的服务器上这样修改,它会破坏所有的工作副本,你的用户会拿着叉子和火把追杀你。