Version 16 (modified by mitty, 11 years ago) (diff)



Apache options

  • Authorization Options > Blanket access control
    • The parameters present on the Limit and LimitExcept directives are HTTP request types that are affected by that block. For example, if you wanted to disallow all access to your repository except the currently supported read-only operations, you would use the LimitExcept directive, passing the GET, PROPFIND, OPTIONS, and REPORT request type parameters. Then the previously mentioned Require valid-user directive would be placed inside the <LimitExcept> block instead of just inside the <Location> block.
      <Location /svn>
        DAV svn
        SVNParentPath /var/svn
        # how to authenticate a user
        AuthType Basic
        AuthName "Subversion repository"
        AuthUserFile /path/to/users/file
        # For any operations other than these, require an authenticated user.
          Require valid-user
  • 単純にRead-onlyにしたければ以下のようにすればよい see also #11
    RedirectMatch ^/svn$ /svn/
    <Location /svn/>
            # Requests for a collection must have a trailing slash on the URI.
            DAV svn
            SVNParentPath /path/to/svn
            SVNListParentPath on
            Order Allow,Deny
            Allow from all
            <LimitExcept GET PROPFIND OPTIONS REPORT>
                    # read-only svn access
                    Order Allow,Deny
                    Deny from all


  • ex) svn ps svn:externals 'libhoge' /path/to/workingcopy/trunk/fuga/
    • svn up /path/to/workingcopy/trunk/fuga/
      Fetching external item into '/path/to/workingcopy/trunk/fuga/libhoge'
      A    /path/to/workingcopy/trunk/fuga/libhoge/piyo.php
      Updated external to revision 275.
    • /path/to/workingcopy/trunk/fuga/libhoge/に幾つかファイルを追加後
    • svn st /path/to/workingcopy/trunk/fuga/
       M      /path/to/workingcopy/trunk/fuga
      X       /path/to/workingcopy/trunk/fuga/libhoge
      ?       /path/to/workingcopy/trunk/fuga/libfuga.txt
      ?       /path/to/workingcopy/trunk/fuga/readme.txt
      ?       /path/to/workingcopy/trunk/fuga/fuga.php
      ?       /path/to/workingcopy/trunk/fuga/favicon.ico
      Performing status on external item at '/path/to/workingcopy/trunk/fuga/libhoge'
      ?       /path/to/workingcopy/trunk/fuga/libhoge/hoge
      ?       /path/to/workingcopy/trunk/fuga/libhoge/hoge.php
      ?       /path/to/workingcopy/trunk/fuga/libhoge/docs

setuid on NFS

  • NFSマウントされたファイルシステム上で、リポジトリ作成後にchmod -R g+ws ${NEWREPOS}/db していると、commit時に以下のようなエラーになる
    svn: Can't get exclusive lock on file '/var/svn/test/db/txn-current-lock': No locks available