You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Thorsten Schöning <ts...@am-soft.de> on 2019/06/11 18:15:45 UTC

mod_dav_dvn+SVNParentPath with non-repo subdirs

Hi all,

I'm hosting SVN-repos using svnserve and by providing the argument
"--root" with the parent dir of all my repos. In the past, all repos
have been placed as a direct child of the given path, but recently I
refactored that to manage repos by customers, topics and stuff. This
works pretty easy with svnserve as it simply forwards all URLs given
by clients into the file system, so one can really simply move repos
into additional subdirs and those get published instantly.

This doesn't work with mod_dav_svn:

> Using this syntax, Apache will delegate the handling of all URLs
> whose path portions begin with /svn/ to the Subversion DAV provider,
> which will then assume that any items in the directory specified by
> the SVNParentPath directive are actually Subversion repositories.

http://svnbook.red-bean.com/en/1.8/svn.serverconfig.httpd.html
https://stackoverflow.com/questions/2701915/svn-multiple-repositories-in-subfolders

I was unable to find reasons and discussions about why things are
implemented differently, if changes have already been suggested etc.
Currently I'm placing a lot "SVNParentPath" in the config of my httpd,
but would be great if one could reduce that in future.

So, is there a reason why mod_dav_svn doesn't support additional
subdirs? Is that likely to be changed? Is it likely that svnserve will
stop supporting addiitonal child dirs?

Thanks!

Mit freundlichen Grüßen,

Thorsten Schöning

-- 
Thorsten Schöning       E-Mail: Thorsten.Schoening@AM-SoFT.de
AM-SoFT IT-Systeme      http://www.AM-SoFT.de/

Telefon...........05151-  9468- 55
Fax...............05151-  9468- 88
Mobil..............0178-8 9468- 04

AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln
AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow


Re: mod_dav_dvn+SVNParentPath with non-repo subdirs

Posted by Thorsten Schöning <ts...@am-soft.de>.
Guten Tag Branko Čibej,
am Samstag, 21. September 2019 um 19:53 schrieben Sie:

> Basically it's as likely as someone contributing a patch for that. Note
> that this may not be trivial due to backwards-compatibility concerns,
> not only about how repositories are found on disk but also (as Daniel
> mentioned) how their names are used in path-based authz rules.

Thanks Daniel and Branko for clarifying this, saves me from retesting
things. :-) Sadly I'm not able to provide a patch, so would only like
to mention that the problem regarding authz-files is worked around by
"AuthzSVNReposRelativeAccessFile" in my setup. This way I simply don't
have repo names in that file and if a new feature like "SVNRoot" is
designed anyway, this might make things easier to start with.

>         <Location "/svn/Src/DocBeam/Clients">
>                 DAV                     svn
>                 SVNParentPath           "/home/ams_svn_repos/Src/DocBeam/Clients"
>                 SVNListParentPath       On
>                 SVNAdvertiseV2Protocol          Off
>                 AuthzSVNReposRelativeAccessFile authz
>         </Location>
>
>         <LocationMatch "^/svn/Src/DocBeam/Clients/[^/]+">
>                 AuthName                "ams_svn_repos/Src/DocBeam/Clients"
>                 AuthType                Basic
>                 PerlAuthenHandler       HttpdAuthnHandler
>                 Require                 valid-user
>         </LocationMatch>

Mit freundlichen Grüßen,

Thorsten Schöning

-- 
Thorsten Schöning       E-Mail: Thorsten.Schoening@AM-SoFT.de
AM-SoFT IT-Systeme      http://www.AM-SoFT.de/

Telefon...........05151-  9468- 55
Fax...............05151-  9468- 88
Mobil..............0178-8 9468- 04

AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln
AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow


Re: mod_dav_dvn+SVNParentPath with non-repo subdirs

Posted by Branko Čibej <br...@apache.org>.
On 11.06.2019 20:15, Thorsten Schöning wrote:
> Hi all,
>
> I'm hosting SVN-repos using svnserve and by providing the argument
> "--root" with the parent dir of all my repos. In the past, all repos
> have been placed as a direct child of the given path, but recently I
> refactored that to manage repos by customers, topics and stuff. This
> works pretty easy with svnserve as it simply forwards all URLs given
> by clients into the file system, so one can really simply move repos
> into additional subdirs and those get published instantly.
>
> This doesn't work with mod_dav_svn:
>
>> Using this syntax, Apache will delegate the handling of all URLs
>> whose path portions begin with /svn/ to the Subversion DAV provider,
>> which will then assume that any items in the directory specified by
>> the SVNParentPath directive are actually Subversion repositories.
> http://svnbook.red-bean.com/en/1.8/svn.serverconfig.httpd.html
> https://stackoverflow.com/questions/2701915/svn-multiple-repositories-in-subfolders


Indeed, svnserve's --root option has a completely different meaning; it
restricts the search for repositories to a specific subtree of the
filesystem. SVNParentPath requires all repositories to be in one directory.


> I was unable to find reasons and discussions about why things are
> implemented differently,

It's most likely due to hysterical ... pardon me, historical reasons.


>  if changes have already been suggested etc.
> Currently I'm placing a lot "SVNParentPath" in the config of my httpd,
> but would be great if one could reduce that in future.
>
> So, is there a reason why mod_dav_svn doesn't support additional
> subdirs? Is that likely to be changed?

Basically it's as likely as someone contributing a patch for that. Note
that this may not be trivial due to backwards-compatibility concerns,
not only about how repositories are found on disk but also (as Daniel
mentioned) how their names are used in path-based authz rules.

Because of these compatibility issues, it's possible that we couldn't
just change the semantics of SVNParentPath but would have to invent a
third option (SVNRoot?).


> Is it likely that svnserve will stop supporting addiitonal child dirs?

No.


-- Brane

Re: mod_dav_dvn+SVNParentPath with non-repo subdirs

Posted by Thorsten Schöning <ts...@am-soft.de>.
Guten Tag Doug Robinson,
am Montag, 12. August 2019 um 23:38 schrieben Sie:

> It works as you'd expect so you should only require one SVNParentPath
> directive assuming that all of your repositories are within that single
> tree.

Just read this today. Are your sure svnadmin and mod_dav_svn behave
the same way? Because I'm somewhat sure to have tried that to be sure
to not need to add many individual configs and it didn't work. Which
would be in-line with what the docs say.

So why do you say otherwise, did you test things or ...?

Mit freundlichen Grüßen,

Thorsten Schöning

-- 
Thorsten Schöning       E-Mail: Thorsten.Schoening@AM-SoFT.de
AM-SoFT IT-Systeme      http://www.AM-SoFT.de/

Telefon...........05151-  9468- 55
Fax...............05151-  9468- 88
Mobil..............0178-8 9468- 04

AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln
AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow


Re: mod_dav_dvn+SVNParentPath with non-repo subdirs

Posted by Doug Robinson <do...@wandisco.com>.
Thorsten:

It works as you'd expect so you should only require one SVNParentPath
directive assuming that all of your repositories are within that single
tree.

I suspect the wording needs a bit of a revamp.

Cheers.

Doug

On Tue, Jun 11, 2019 at 2:15 PM Thorsten Schöning <ts...@am-soft.de>
wrote:

> Hi all,
>
> I'm hosting SVN-repos using svnserve and by providing the argument
> "--root" with the parent dir of all my repos. In the past, all repos
> have been placed as a direct child of the given path, but recently I
> refactored that to manage repos by customers, topics and stuff. This
> works pretty easy with svnserve as it simply forwards all URLs given
> by clients into the file system, so one can really simply move repos
> into additional subdirs and those get published instantly.
>
> This doesn't work with mod_dav_svn:
>
> > Using this syntax, Apache will delegate the handling of all URLs
> > whose path portions begin with /svn/ to the Subversion DAV provider,
> > which will then assume that any items in the directory specified by
> > the SVNParentPath directive are actually Subversion repositories.
>
> http://svnbook.red-bean.com/en/1.8/svn.serverconfig.httpd.html
>
> https://stackoverflow.com/questions/2701915/svn-multiple-repositories-in-subfolders
>
> I was unable to find reasons and discussions about why things are
> implemented differently, if changes have already been suggested etc.
> Currently I'm placing a lot "SVNParentPath" in the config of my httpd,
> but would be great if one could reduce that in future.
>
> So, is there a reason why mod_dav_svn doesn't support additional
> subdirs? Is that likely to be changed? Is it likely that svnserve will
> stop supporting addiitonal child dirs?
>
> Thanks!
>
> Mit freundlichen Grüßen,
>
> Thorsten Schöning
>
> --
> Thorsten Schöning       E-Mail: Thorsten.Schoening@AM-SoFT.de
> AM-SoFT IT-Systeme      http://www.AM-SoFT.de/
>
> Telefon...........05151-  9468- 55
> Fax...............05151-  9468- 88
> Mobil..............0178-8 9468- 04
>
> AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln
> AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow
>
>

-- 
*DOUGLAS B ROBINSON* SENIOR PRODUCT MANAGER

T +1 925 396 1125
*E* doug.robinson@wandisco.com

-- 


* <http://wandisco.com>*

**The LIVE DATA Company
*Find out more 
*wandisco.com <http://wandisco.com/>*



 
<https://www.wandisco.com/welcome-live-data-world-video>
*


THIS MESSAGE 
AND ANY ATTACHMENTS ARE CONFIDENTIAL, PROPRIETARY AND MAY BE PRIVILEGED

If 
this message was misdirected, WANdisco, Inc. and its subsidiaries, 
("WANdisco") does not waive any confidentiality or privilege. If you are 
not the intended recipient, please notify us immediately and destroy the 
message without disclosing its contents to anyone. Any distribution, use or 
copying of this email or the information it contains by other than an 
intended recipient is unauthorized. The views and opinions expressed in 
this email message are the author's own and may not reflect the views and 
opinions of WANdisco, unless the author is authorized by WANdisco to 
express such views or opinions on its behalf. All email sent to or from 
this address is subject to electronic storage and review by WANdisco. 
Although WANdisco operates anti-virus programs, it does not accept 
responsibility for any damage whatsoever caused by viruses being passed.

Re: mod_dav_dvn+SVNParentPath with non-repo subdirs

Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
Thorsten Schöning wrote on Tue, Jun 11, 2019 at 20:15:45 +0200:
> So, is there a reason why mod_dav_svn doesn't support additional
> subdirs? Is that likely to be changed?

I can't think of a reason against adding that.

> Is it likely that svnserve will stop supporting addiitonal child dirs?

No.

One more thing: IIRC, svnserve and SVNPath use different values for the
repository name in [reposname:/path/in/repository] authz rules.

Cheers,

Daniel