1

I'm currently running three repositories with svnserve, all in /var/svn, all with a different passwd file (used by subversion, so /var/svn/the-repo/conf/passwd) of course. I'm also using apache with the DAV SVN module, like this:

<VirtualHost 127.0.0.1:8080>
        ServerName svn.my-server.com
        ErrorLog /var/log/virtualmin/svn.my-server.com/error_log
        CustomLog /var/log/virtualmin/svn.my-server.com/access_log combined
        <Location />
                DAV svn
                SVNParentPath /var/svn/
                SVNListParentPath On
        </Location>
</VirtualHost>

This is working perfectly. However, when I browse to http://svn.myserver.com/repo-1, I am not asked for authentication: I'm able to view everything without providing credentials.

I know how to make apache ask me for credentials using HTTP authentication. But what I would like, is to have apache use the same authentication as svnserve. Is this possible?

Later, I might add new repositories. I would like that I don't have to configure apache again, then.


I suppose it doesn't change anything, but I'm using nginx as a proxy to apache.

1 Answer 1

1

I know how to make apache ask me for credentials using HTTP authentication. But what I would like, is to have apache use the same authentication as svnserve. Is this possible?

Nope, it is not. You have to configure authentication in Apache separately. See SVNBook | httpd, the Apache HTTP Server | Authentication Options.

Later, I might add other repositories to the same directory /var/svn. I would like that I don't have to configure apache again, then.

Since you say that you gonna add repos in future, you can stay with SVNParentPath but you have to use only one htpasswd file for all of your repos.

Sign up to request clarification or add additional context in comments.

7 Comments

I'm sorry for the unclarity, but the different passwd files I was talking about are the passwd files used by subversion, in the-repo/conf/passwd, not htpasswd files as could be used by apache's basic authentication.
@CamilStaps aw, my bad. I misunderstood this part. Then the answer would be just "no, you can't".
@CamilStaps what's the use case to expose your repos via svnserve and httpd at the same time?
In that case you could just drop svnserve and have the clients use http as well.
Ah, I was not aware of the existence of a web interface, and didn't think of that. Thank you very much!
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.